SQL Database

Data definition

Normalization

Data Manipulation

Latest Posts

  • Master the Art of Creating Tables in SQL: A Step-by-Step Guide to Database Design

    ·

    Master the Art of Creating Tables in SQL: A Step-by-Step Guide to Database Design

    Are you ready to unlock the power of SQL and become a master of database design? Look no further! In this comprehensive step-by-step guide, we will take you on a journey through the art of creating tables in SQL. Whether you are a beginner or an experienced programmer, this guide will provide you with the…

  • CREATE VIEW Side Effects

    ·

    CREATE VIEW Side Effects

    So what happens when you create a view, and then later someone else changes the underlying tables? In this article let’s explore a simple scenario, check out how the SQL view handles the change, and what we can learn from viewing the data dictionary. Create View Scenario Imagine we are accepting data from a table…

  • Database Design In Four Steps – Build the Sample PizzaDB

    ·

    Database Design In Four Steps – Build the Sample PizzaDB

    In this article we are going to design and create a sample relational database you can use with MySql, PostgreSQL or Microsoft SQL Server.  Though SQL is mostly the same within these products, I’ll be sure to point out differences so you can easily follow along using your favorite DBMS (Database Management System). In our…

  • CREATE TABLE SQL

    ·

    CREATE TABLE SQL

    You can use the SQL CREATE TABLE command to create a new table in the database.  When you create a table you define the table name, the columns, data types, and any constraints against them. You initially create tables empty, so you’ll need to use the insert statement to add data into it.  If you’re…

  • Data Modeling Principles in Action
    ,

    ·

    Data Modeling Principles in Action

    In this puzzle, we’re going to learn how to do some basic data modeling.  Many of you have expressed an interest in learning more about data modeling and database design.  I figure we could start with a simple case study and let it evolve from there. Solving puzzles is a great way to learn SQL. …

  • Primary Key vs Unique Key – What is the Difference?
    ,

    ·

    Primary Key vs Unique Key – What is the Difference?

    Primary Key vs Unique Key. It really not about one or the other. You actually may need both a primary key and unique key in your table. In this article we learn the difference between a primary key and unique key, and why both are important to maintaining a relational database structure. All the examples…

  • What is a SQL Server Data Dictionary?

    ·

    What is a SQL Server Data Dictionary?

    What is a Data Dictionary? The SQL Server data dictionary stores information about a database’s definition.  The dictionary contains information about database objects such as tables, indexes, columns, datatypes, and views. The SQL Server DBMS uses the data dictionary to execute queries. The data dictionary is kept up-to-date as the database objects are changed. All…

  • Database Normalization – in Easy to Understand English

    ·

    Database Normalization – in Easy to Understand English

    Database normalization is a process used to organize a database into tables and columns. There are three main forms: first normal form , second normal form, and third normal form. The main idea is each table should be about a specific topic and only supporting topics included. Take a spreadsheet containing the information as an…

  • Foreign Key vs Primary Key – What is the Difference?

    ·

    Foreign Key vs Primary Key – What is the Difference?

    This article will teach you the difference between a primary key and foreign key. This article will also teach you why both of these keys are important when it comes to the maintenance of a relational database structure. All the examples for this lesson are based on Microsoft SQL Server Management Studio and the AdventureWorks…

  • Keep it Simple:  Easy To Understand Data Modeling Concepts

    ·

    Keep it Simple: Easy To Understand Data Modeling Concepts

    When working with SQL databases it is often useful to create diagrams of the database tables and their relationships.  These may be done during the design process, as  your data modeling, or once the database is created, in order to document the tables’ dependencies.  As I explain various concepts in my lessons, I’ll sometimes use…

  • What is a Relational Database View?

    ·

    What is a Relational Database View?

    A database view is a searchable object in a database that is defined by a query.  Though a view doesn’t store data, some refer to a views as “virtual tables,” you can query a view like you can a table.  A view can combine data from two or more table, using joins, and also just…

  • Database Indexes Explained
    ,

    ·

    Database Indexes Explained

    A database index allows a query to efficiently retrieve data from a database.  Indexes are related to specific tables and consist of one or more keys.  A table can have more than one index built from it.  The keys are a fancy term for the values we want to look up in the index.  The…

  • What is a Database Table?
    ,

    ·

    What is a Database Table?

    A relational database is made up of several components, of which the table is most significant.  The database table is where all the data in a database is stored, and without tables, there would not be much use for relational databases. Overall Structure of a Database Table A database consists of one or more tables. …

  • Database Management System Main Parts
    ,

    ·

    Database Management System Main Parts

    The main objective of a database management system is to store, retrieve, and process data.  In order to do this in a safe and efficient manner, several major components work together to achieve this aim.  They are:

  • What are the Major Part of a SQL DB?
    ,

    ·

    What are the Major Part of a SQL DB?

    A SQL database is used to store and retrieve data.  The database is housed in a database server and largely controlled by a database management system.  All SQL databases, whether they MS SQL Server, MySQL, Oracle, or Progress have several components in common.  They are: Tables Indexes Views Stored Procedures Triggers It is these various…