MySQL Table Operations
- The statement to change the table name is __________.
-
View Hint View Answer Discuss in Forum
NA
Correct Option: A
To change the name of a table, the keyword ‘RENAME’ can be used. It can be used with the ‘ALTER TABLE’ clause. It can also be used as a statement in itself like ‘RENAME TABLE old_tbl new_tbl’.
- The default index type for MEMORY tables is __________
-
View Hint View Answer Discuss in Forum
NA
Correct Option: D
The ‘HASH’ index is the default index type for ‘MEMORY’ tables. ‘SPATIAL’ can only be used with ‘MyISAM’ tables for the spatial data types. ‘FULLTEXT’ is used for performing full-text searches.
- It is possible to drop multiple tables in the same statement.
-
View Hint View Answer Discuss in Forum
NA
Correct Option: B
To drop a table, all that is required is the table name. No additional information like table format or type is necessary. Multiple tables are dropped in the same DROP TABLE statement.
- Which storage engine enables to access tables from a MySQL server managed by another server?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: A
There are many storage engines that are used in MySQL. By default, MyISAM is used as the storage engine unless specified otherwise. FEDERATED enables access to a foreign MySQL server.
- Which keyword is used to create a table as a temporary copy of itself?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: A
The ‘CREATE TABLE’ clause has a very vast formal format, although its usage is extremely simple and intuitive. One of the many ways is to create a table as a temporary copy of itself.