149k views
0 votes
The column names used in the view must be the same names as the column names in the underlying table(s).​

A) True
B) False

1 Answer

2 votes

Final answer:

The statement is false; column names in a view can be different from the column names in the underlying tables. You can define a column with a different name in a view by including the new name in the view's definition.

Step-by-step explanation:

The statement that the column names used in the view must be the same names as the column names in the underlying table(s) is false. In SQL, a view is a virtual table based on the result-set of an SQL statement, and it can have columns named differently than those in the underlying tables. To define a column with a different name in a view, you simply include the new name in the view's definition. For example:

CREATE VIEW my_view AS
SELECT old_column_name AS new_column_name
FROM my_table;

This will create a view where 'old_column_name' from 'my_table' is now referred to as 'new_column_name' in 'my_view'.

User Abel D
by
8.3k points