Home > Database > Mysql Tutorial > body text

How to add value to mysql?

青灯夜游
Release: 2020-10-26 15:31:08
Original
2639 people have browsed it

Method to add value to mysql: Use the "INSERT INTO" statement to insert one or more rows of data into an existing table in the database; the syntax format is "INSERT INTO table name [column name 1 [, ... column name n] ] VALUES (value 1) [… , (value n)];”.

How to add value to mysql?

(Recommended tutorial: mysql video tutorial)

After the database and table are successfully created, you need to add the database table Insert data into . In MySQL, you can use the INSERT INTO statement to insert one or more rows of tuple data into an existing table in the database.

Basic syntax

The syntax format of INSERT INTO is:

INSERT INTO <表名> [ <列名1> [ , … <列名n>] ]
VALUES (值1) [… , (值n) ];
Copy after login

The syntax description is as follows.