MySQL: Difference between revisions
Jump to navigation
Jump to search
Created page with " <syntaxhighlight lang="bash"> # Connect to mysql server mysql --host=<ip.address> --user=<username> --password=<password> </syntaxhighlight>" |
No edit summary |
||
| Line 1: | Line 1: | ||
== MySQL == | |||
Connecting to MySQL server in bash | |||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
# Connect to mysql server | # Connect to mysql server | ||
mysql --host=<ip.address> --user=<username> --password=<password> | mysql --host=<ip.address> --user=<username> --password=<password> | ||
</syntaxhighlight> | |||
MySQL commands | |||
<syntaxhighlight lang="mysql"> | |||
show databases; # show the databases | |||
use userdata_schema; # connect to a particular database | |||
show tables; # list the tables within the database | |||
select * from table_name limit 10; # to see what's in a table (first ten entries) | |||
</syntaxhighlight> | </syntaxhighlight> | ||
Revision as of 00:26, 30 November 2015
MySQL
Connecting to MySQL server in bash
# Connect to mysql server
mysql --host=<ip.address> --user=<username> --password=<password>MySQL commands
show databases; # show the databases
use userdata_schema; # connect to a particular database
show tables; # list the tables within the database
select * from table_name limit 10; # to see what's in a table (first ten entries)