Q1
True / FalseIn SQL Server, each row in a table must have a unique identifier.
While having a unique identifier is good practice, it's not a requirement for each row. However, using primary keys is recommended for uniqueness.
Q2
True / FalseSQL Server allows columns to have default values.
SQL Server supports default values for columns, which are used when no value is provided during data insertion.
Q3
True / FalseIn SQL Server, a column's data type cannot be changed once the table is created.
SQL Server allows modification of a column's data type using the ALTER TABLE command.
Q4
True / FalseThe ROW_NUMBER() function in SQL Server can be used to assign a unique number to each row.
The ROW_NUMBER() function generates a unique sequential integer for rows within a result set.
Q5
True / FalseSQL Server allows NULL values in columns by default.
By default, SQL Server allows NULL values in columns unless specified otherwise using the NOT NULL constraint.
Q6
True / FalseIn SQL Server, columns can be set to automatically increment their values.
SQL Server supports the IDENTITY property for columns to automatically increment values.
Q7
True / FalseSQL Server's ALTER TABLE command can add new columns to an existing table.
The ALTER TABLE command can be used to add new columns to an existing table in SQL Server.
Q8
True / FalseA column with the UNIQUE constraint in SQL Server allows duplicate values.
The UNIQUE constraint ensures that all values in a column are distinct across the table.
Q9
True / FalseIn SQL Server, a table can have multiple columns with the same name.
Each column in a table must have a unique name to avoid ambiguity and ensure proper data management.
Q10
True / FalseSQL Server supports creating tables with columns of various data types, including user-defined types.
SQL Server supports a wide range of data types, including user-defined types for more customized data handling.
Q11
True / FalseThe SQL Server function COUNT(*) can count rows even if some columns have NULL values.
COUNT(*) counts all rows in a table, regardless of NULL values in any columns.
Q12
True / FalseSQL Server allows columns in a table to have default values assigned only at the time of table creation.
Default values for columns can be set both at the time of table creation and later using the ALTER TABLE command.
Q13
True / FalseThe DISTINCT keyword in SQL Server can be used to eliminate duplicate rows from a query result.
The DISTINCT keyword removes duplicate rows from the result set of a query in SQL Server.
Q14
True / FalseSQL Server does not allow altering the data type of a column if it contains existing data.
SQL Server allows altering a column's data type even if it contains existing data, provided the conversion is valid.
Q15
True / FalseIn SQL Server, rows and columns in a table are always ordered based on their insertion sequence.
Rows and columns in SQL Server tables are not inherently ordered by their insertion sequence. Ordering is controlled by the query results using ORDER BY.