Take the person table as an example under the ORCL instance:
1. Log in to MySQL:
MySQL installation path, bin directory, Open command window, enter mysql-u user name-p password;
2. Show all instances, show databases;
3. Enter ORCL instance, use ORCL;
4. Display the Person table field information, desc person;
5. Modify the field description, ALTER TABLE person change PID pid Int (one) not null;
6. Modify the table name, ALTER TABLE person rename to people;
7. Check, select *from person;
8. Add, insert into person (name,age,birthday,salary) VALUES (' Ming ', 11, ' 1999-01-01 ', 1000);
9. Change, update person set name = ' Xiaoli ' where pid = 11;
10. Delete from the person where PID = 10;
11. Number, select COUNT (1), age from person group by age;
12. Sort, select name,salary from Person order by salary ASC;
Select Name,salary from person order by salary desc;
Learn simple database table operations (MYSQL) 2