SQL Server Interview Question #6
What is a table in SQL Server?
SQL Server Fundamentals Junior Beginner
Detailed Explanation
A table is a database object used to store related data in rows and columns. Columns define attributes and data types, while each row represents an individual record.
A Products table, for example, can contain Id, Name, Price, and IsActive columns.
Code Example
CREATE TABLE Products
(
Id INT PRIMARY KEY,
Name NVARCHAR(200) NOT NULL,
Price DECIMAL(18,2) NOT NULL,
IsActive BIT NOT NULL
);