CBSE Class 11 Informatics Practices Question 7 of 40

Practice Paper — Question 7

Back to all questions
7
Question

Question 7

Anu wants to change the width of a column Author in a Table Library from Varchar(20) to Varchar(30). Which command should she use?

Answer

Anu should use MODIFY clause with ALTER TABLE command to modify the data type size for the Author column from 20 to 30 characters. The command is as follows:

ALTER TABLE Library
MODIFY Author VARCHAR(30);