Results: 1580
Notes
  • Newest first
  • Oldest first
  • Newest first(All)
  • Oldest first(All)
Shows all the databases that the current user has access to
SHOW DATABASES
The following query is a synonym of the above query. Both of them list all the databases on the MySQL host:
SHOW SCHEMAS
by Valeri Tandilashvili
4 years ago
0
MySQL
SHOW
Full MySQL Course for Beginners
1
SHOW SCHEMAS
Lists all the databases on the MySQL host:
SHOW SCHEMAS
Note: The above query is a synonym for
SHOW DATABASES
by Valeri Tandilashvili
4 years ago
0
MySQL
SHOW
1
Lists all the tables from the specified MySQL database
UniversityDB
SHOW TABLES FROM UniversityDB
by Valeri Tandilashvili
4 years ago
0
MySQL
SHOW
Full MySQL Course for Beginners
1
Lists all the columns from the specified table
SHOW COLUMNS FROM students
Shortcut of the query above is
DESCRIBE
DESCRIBE students
by Valeri Tandilashvili
4 years ago
0
MySQL
Full MySQL Course for Beginners
1
SHOW COLUMNS from a table with specifying a database
Lists all the columns from
students
table that is in the
university
database
SHOW COLUMNS FROM university.students
Another method to specify a database when listing columns from a table
SHOW COLUMNS FROM students IN university
by Valeri Tandilashvili
4 years ago
0
MySQL
SHOW
1
Lists all the columns from students table
DESCRIBE students
Note: the query above is alternative and shortcut of
SHOW COLUMNS FROM students
by Valeri Tandilashvili
4 years ago
0
MySQL
DESCRIBE
Full MySQL Course for Beginners
1
USE database
Selects the specified database so that after running the query we don't need to specify the database for other queries related to the specified one
USE university
For example we can list all columns from any of the table inside the selected database without specifying it. MySQL will know that we mean already the selected database
SHOW COLUMNS FROM students
by Valeri Tandilashvili
4 years ago
0
MySQL
USE
1
EXPLAIN
provides detailed information about the query result. One of the information that
EXPLAIN
gives us is how many rows will be affected after running the query
EXPLAIN UPDATE students SET mail = 'email@gmail.com' WHERE id > 39
Note:
EXPLAIN
works with the following statements:
SELECT
,
DELETE
,
INSERT
,
REPLACE
,
UPDATE
by Valeri Tandilashvili
4 years ago
0
MySQL
EXPLAIN
Full MySQL Course for Beginners
1
System variables start with two
at signs
-
@
. Shows base directory of MySQL
SELECT @@basedir
Shows whether query uses cache or not
SELECT @@have_query_cache
Shows what size does query cache have
SELECT @@query_cache_size
... Shows complete list of system variables with their values
SHOW VARIABLES
Complete list of system variables using
phpmyadmin
: phpmyadmin/server_variables.php
by Valeri Tandilashvili
4 years ago
0
MySQL
System variables
Full MySQL Course for Beginners
1
SHOW VARIABLES
Lists all the system variables with their values
SHOW VARIABLES
by Valeri Tandilashvili
4 years ago
0
MySQL
SHOW
1
Results: 1580