MCQ Single Best Answer Easy

QWhich of the following statements is true about the TRUNCATE TABLE statement in MySQL?

ID: #15459 Data definition language - MySQL 129 views
Question Info
#15459Q ID
EasyDifficulty
Data definition language - MySQLTopic

Choose the Best Option

Click any option to instantly check if you're correct.

  • A TRUNCATE TABLE deletes the table structure and its data.
  • B TRUNCATE TABLE removes the table structure but preserves its data.
  • C TRUNCATE TABLE only removes the data from a table.
  • D TRUNCATE TABLE is not a valid statement in MySQL.
Correct Answer: Option A

Explanation

The TRUNCATE TABLE statement in MySQL is used to delete all data from a table while preserving the table structure. It is a faster alternative to the DELETE statement for removing all rows from a table.

Share This Question

Challenge a friend or share with your study group.