How to do like above. Is it difficult to do? How to start playing with terminal as *hacker *:) just kidding.
I am so bored when creating database and it's different table with Graphical User Interface (GUI). That's why I will help those who want to dirty their hands with command line.
Here it goes with answer of How to start?
Configure all environments (xampp) / any mysql
type mysql in cmd
type mysql -u user_name -p password
after successfull
mysql>
- To list database type the following command
mysql>show databases;
output:
+--------------------+
| Database |
+--------------------+
| coronadb |
| ecomm |
| ecommerce |
| information |
| information_schema |
| mysql |
| performance_schema |
| phpmyadmin |
| test |
| test1 |
| testdatabase |
| user_login |
+--------------------+
12 rows in set (0.001 sec)
- To use these database and to list available tables type the following two commands:
mysql>use user_login;
- Now list tables:
mysql[database_name]>show tables;
output
+---------------------------+
| Tables_in_mysql |
+---------------------------+
| columns_priv |
| db |
| func |
| help_category |
| help_keyword |
| help_relation |
| help_topic |
| host |
| proc |
| procs_priv |
| tables_priv |
| time_zone |
| time_zone_leap_second |
| time_zone_name |
| time_zone_transition |
| time_zone_transition_type |
| user |
+---------------------------+
17 rows in set (0.00 sec)
These are command line sql for starting in command line instead of GUI.
Read sql docs and start future operation like insert,delete,filter,etc.
I will continue and help you guys to explore more on this topic.
Thanks for reading.
Recommend me any suggestion or how to improve. Or any topic?
Happy hacking.
Sign out for today.
Top comments (0)