In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "mysql how to add tables", the content of the article is simple and clear, easy to learn and understand, the following please follow the editor's ideas slowly in depth, together to study and learn "mysql how to add tables" bar!
In mysql, you can use the "CREATE TABLE" statement to add tables, which is used to create tables in the database, and to specify the data type that the column can hold. The syntax is "CREATE TABLE table name (column name 1 data type, column name 2 data type,..)".
The operating environment of this tutorial: windows10 system, mysql8.0.22 version, Dell G3 computer.
How to add tables to mysql
CREATE TABLE statement
The CREATE TABLE statement is used to create tables in the database.
SQL CREATE TABLE syntax
CREATE TABLE table name (column name 1 data type, column name 2 data type, column name 3 data type,....)
The data type (data_type) specifies what data type the column can hold. The following table contains the most commonly used data types in SQL:
Examples are as follows:
How to create a table named "Person".
The table contains five columns with the names of "Id_P", "LastName", "FirstName", "Address" and "City":
CREATE TABLE Persons (Id_P int,LastName varchar, FirstName varchar, Address varchar, City varchar)
The data type of the Id_P column is int and contains integers. The data type of the remaining four columns is varchar, with a maximum length of 255characters.
The empty "Persons" table looks like this:
Thank you for your reading, the above is the content of "mysql how to increase the table", after the study of this article, I believe you have a deeper understanding of how to increase the form of mysql, the specific use of the situation also needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.