1.3 Managing Databases Flashcards
What is a database system instance?
A database system instance is a single executing copy of a database system.
How many instances of a database system do personal computers usually run?
Personal computers usually run just one instance of a database system.
How many instances of a database system do shared computers typically run?
Shared computers, such as those used for cloud services, usually run multiple instances of a database system.
What does the command CREATE DATABASE DatabaseName do?
CREATE DATABASE DatabaseName creates a new database.
What does the command DROP DATABASE DatabaseName do?
DROP DATABASE DatabaseName deletes a database, including all tables in the database.
What is the purpose of the USE DatabaseName command?
USE DatabaseName selects a default database for use in subsequent SQL statements.
What does the command SHOW DATABASES do?
SHOW DATABASES lists all databases in the database system instance.
What does the command SHOW TABLES do?
SHOW TABLES lists all tables in the default database.
What does the command SHOW COLUMNS FROM TableName do?
SHOW COLUMNS FROM TableName lists all columns in the TableName table of the default database.
What does the command SHOW CREATE TABLE TableName do?
SHOW CREATE TABLE TableName shows the CREATE TABLE statement for the TableName table of the default database.