From the course: SQL Server 2014 Essential Training

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Understanding data column options

Understanding data column options - SQL Server Tutorial

From the course: SQL Server 2014 Essential Training

Start my 1-month free trial

Understanding data column options

- Now, let's look at some more options when creating or designing a table. So I'm gonna go back to the table we created in the previous exercise, the People table, I'll right click on it, and I'll choose the second option from the top, which is Design. And that will open up an interface very similar to when we created the table. So here we can add another column, and the column I'd like to add now, is an ID field. An ID field to provide a unique identifier for every row in this table, just in case we have two people that have the same first name, and same last name, we'll need a way to distinguish those two people as individuals, so we'll just create a column that numbers every row. I'll call the column PersonID, and for the Data Type, I'll use an integer, which is just int, and we're gonna clear the box that allows nulls, because I don't want this value to be null. There are some other column options we'll need to set, and those will come up in the bottom half of this interface. So…

Contents