English

A customer table is created with cno,cname, and address columns. Evaluate the following statement whether it is correct or not? Delete cname from customer;

Advertisements
Advertisements

Question

A customer table is created with cno,cname, and address columns. Evaluate the following statement whether it is correct or not?

Delete cname from customer;

Code Writing
Advertisements

Solution

The statement is incorrect. DELETE removes rows, not columns. To remove a column, use:

ALTER TABLE customer
DROP COLUMN cname;
shaalaa.com
  Is there an error in this question or solution?
Chapter 10: Structure Query Language - EXERCISE [Page 196]

APPEARS IN

CBSE Computer Science with Python [English] Class 12
Chapter 10 Structure Query Language
EXERCISE | Q 5. | Page 196
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×