Columns
Names describe what information each record can contain.
A table is a structured collection of related records organized into rows and columns.
A table is a structured collection of related records organized into rows and columns.
A table usually represents one entity or one category of related data. For example, a users table stores users, and an orders table stores orders.
Simple idea: one table keeps one kind of record in a predictable shape.
Think of a spreadsheet tab made for one kind of thing. The column headings name the details, and each horizontal line holds one complete record.
The whole organized set of related records.
One complete record, such as one user.
One named kind of information, such as email.
The actual value at one row and one column.
In a Users table, Rebecca is a field value in the name column of one row.
A database table defines how related records can be stored, checked, found, and connected.
Names describe what information each record can contain.
Rules say whether a value is text, a number, a date, or another type.
Keys identify or connect records, while constraints protect data quality.
References can connect records in this table to records in another table.
Tables are used anywhere an application needs to manage many related records.
One row for each account.
Contact details and preferences.
Purchases and their status.
Names, prices, and stock details.
Quantities available at each location.
Here is a real-looking users table. The header row names the columns. Each line below it is one row, or one user record.
| id | name | created_at | |
|---|---|---|---|
| 1 | Rebecca | rebecca@example.com | 2026-09-10 |
| 2 | Alex | alex@example.com | 2026-09-10 |
Read one cell: in the first row, Rebecca is the field value for the name column. The full row describes one user.
CREATE TABLE users (
id INTEGER PRIMARY KEY,
name TEXT NOT NULL,
email TEXT NOT NULL UNIQUE,
created_at DATE NOT NULL
);This SQL defines the table’s columns, data types, primary key, and constraints. The stored rows then follow that shape.
The database contains tables. A table contains rows and columns. Its schema defines the rules, keys connect the data, and SQL is used to work with it.
A table represents one entity or category of related data.
Rows are records, columns describe the records, and each cell holds a field value.
A table’s schema, keys, constraints, and relationships help keep data useful and connected.