What is a Database Table?
What is a Database Table?
A Relational Database Management System( RDBMS) organizes and stores information in the form of tables. The Relational model store information about real-world things in a database table.
Database Table
A table is an ordered collection of one or more columns and an unordered collection of zero or more
rows. Each column in the table has a name and a data type. Each table row has exactly one value
for each column. The values in the table are atomic. A particular row and a particular
column can contain only one piece of data.
MySQL Server can manage multiples databases or schemas. Each database can have multiple database tables.
For example, the database tables in MySQL world database can be listed using the following command:
mysql> SHOW TABLES;
Table Structure
To know the table structure i.e number of columns, column data types, table constraints, etc.
mysql> DESCRIBE City;
+————-+———-+——+—–+———+—————-+
| Field | Type | Null | Key | Default | Extra |
+————-+———-+——+—–+———+—————-+
| ID | int | NO | PRI | NULL | auto_increment |
| Name | char(35) | NO | | | |
| CountryCode | char(3) | NO | MUL | | |
| District | char(20) | NO | | | |
| Population | int | NO | | 0 | |
+————-+———-+——+—–+———+—————-+
5 rows in set (0.05 sec)
—
MySQL Tutorials
MySQL Tutorials on this website:
https://www.testingdocs.com/mysql-tutorials-for-beginners/