Home >Database >Mysql Tutorial >How to insert data into table in mysql
MySQL is a relational database management system developed by Swedish MySQL AB and currently owned by Oracle. MySQL is a relational database management system that stores data in different tables instead of putting all the data in one big warehouse, which increases speed and flexibility.
How to insert data into the table in mysql?
The insert into command is used to insert data into the table.
insert into command format:
insert into <表名> [(<字段名1>[,..<字段名n > ])] values ( 值1 )[, ( 值n )];
For example:
Insert two records into the table MyClass. These two records represent: number 1 The score of number 2 named Joan is 82.99, and number 3 named Wang has a score of 96.5.
mysql> insert into MyClass values(1,'Tom',96.45),(2,'Joan',82.99), (2,'Wang', 96.59);
Note: insert into can only insert one record into the table at a time.
The above is the detailed content of How to insert data into table in mysql. For more information, please follow other related articles on the PHP Chinese website!