Documente Academic
Documente Profesional
Documente Cultură
Outline
Background of mySQL ANSI SQL Standards mySQL and other Databases Operating Systems Supported Connecting to and Disconnecting from the Server Creating and Using Database mySQL in Batch Mode Database Administration
Outline
Column Data Types DDL (Data Definition Language) specifics mySQL Table Types mySQL ODBC Support Laboratory Exercise
Background of mySQL
MySQL, the most popular Open Source SQL database, is developed, distributed and supported by MySQL AB. MySQL AB is a commercial company founded by the MySQL developers that builds its business providing services around the MySQL database
mysql> SHOW TABLES; To create a new table mysql> CREATE TABLE student (student_id VARCHAR(8), student_name VARCHAR(20), student_course VARCHAR(20)); To show tables structure mysql> DESC student; To drop table mysql> DROP TABLE student;
Database Administration
GRANT priv_type [(column_list)] [, priv_type [(column_list)] ...] ON {tbl_name | * | *.* | db_name.*} TO user_name [IDENTIFIED BY [PASSWORD] 'password'] [, user_name [IDENTIFIED BY 'password'] ...] [REQUIRE NONE | [{SSL| X509}] [CIPHER cipher [AND]] [ISSUER issuer [AND]] [SUBJECT subject]] [WITH [GRANT OPTION | MAX_QUERIES_PER_HOUR # | MAX_UPDATES_PER_HOUR # | MAX_CONNECTIONS_PER_HOUR #]] REVOKE priv_type [(column_list)] [, priv_type [(column_list)] ...] ON {tbl_name | * | *.* | db_name.*} FROM user_name [, user_name ...] FLUSH PRIVILEGES