CameraIcon
CameraIcon
SearchIcon
MyQuestionIcon
MyQuestionIcon
2
You visited us 2 times! Enjoying our articles? Unlock Full Access!
Question

Which of the following SQL statement is used to delete a column from a table ___________________.

A
DELETE column-name from table name
No worries! We‘ve got your back. Try BYJU‘S free classes today!
B
ALTER TABLE table name DROP COLUMN column name
Right on! Give the BNAT exam to get a 100% scholarship for BYJUS courses
C
DROP column name FROM table name
No worries! We‘ve got your back. Try BYJU‘S free classes today!
D
None of the above
No worries! We‘ve got your back. Try BYJU‘S free classes today!
Open in App
Solution

The correct option is B ALTER TABLE table name DROP COLUMN column name

SQL statement is used to delete a column from a table.

ALTER TABLE table name DROP COLUMN column name.

ALTER TABLE statement to add a column, modify a column, drop a column, rename a column or rename a table.


The ALTER TABLE statement is also used to add and drop various constraints on an existing table.


Structured query language uses a collection of imperative verbs whose effect is to modify the schema of the database by adding, changing, or deleting definitions of tables or other elements.


flag
Suggest Corrections
thumbs-up
0
Join BYJU'S Learning Program
similar_icon
Related Videos
thumbnail
lock
Database Structuring
ACCOUNTANCY
Watch in App
Join BYJU'S Learning Program
CrossIcon