In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
What is the basic concept of SQL Server table, many novices are not very clear about this, in order to help you solve this problem, the following small series will explain in detail for everyone, there are people who need this can learn, I hope you can gain something.
Basic concepts of SQL Server tables
A table is a database object that contains all the data in the database. Data is organized in tables in a similar way to spreadsheets, organized in rows and columns. Each row represents a unique record, and each row represents a field in the record.
Tables in SQL Server include the following major components:
Columns: Each column represents an attribute of the object modeled by the table. For example, the employee table has number columns, name columns, and title columns;
Rows: Each row represents a separate instance of the object modeled by the table. For example, each employee of the company occupies a row in the table;
data integrity
1) Physical integrity
Entity integrity defines rows as unique entities for a particular table. Entity integrity enforces the integrity of a table's identity column or primary key by UNIQUE index, UNIQUE constraint or PRIMARYKEY constraint;
2) Domain integrity
Domain integrity refers to the validity of items for a particular column. Domain integrity can be enforced by restricting types (by using data types), by restricting formats (by using CHECK constraints and rules), or by restricting the range of possible values (by using FOREIGNKEY constraints, CHECK constraints, DEFAULT definitions, NOT NULL definitions, and rules);
3) Integrity of references
When you enter or delete rows, you reference the relationships defined between integrity preserving tables. When referential integrity is enforced, SQL Server prevents users from:
Add or change rows in related tables when there are no associated rows in the main table;
Change values in the main table (can cause orphaned rows in related tables);
delete rows in the main table if there are matching related rows;
4) User-defined integrity rules
User-defined integrity can define specific business rules that do not belong to any other integrity category. All integrity classes support user-defined integrity, which includes all column-level and table-level constraints, stored procedures, and triggers in CREATE TABLE;
primary key
A primary key uniquely identifies row data in a table. A primary key corresponds to a row of data. A primary key consists of one or more fields, and its value is unique. NULL is not allowed. A table can only have one primary key.
Did reading the above help you? If you still want to have further understanding of related knowledge or read more related articles, please pay attention to the industry information channel, thank you for your support.
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.