以下这些内容是了解SQL Server中table必须掌握的,至于其中的各个知识点,我会在以后的文章中逐一进行详述!
Table
1.
Create table:
CREATE
TABLE dbo.customer
(
cust_id int,
cust_name char(12),
cust_phone char(11)
)
Explanation:
a. The full name of a table should have three parts, in the following form:
database.schema.tablename
b. “dbo” represented
Schema.
2.
Data Types in SQL Server 2005:
1) Numeric Data Types
2) Date and Time Data Types
3) Character Data Types
4) Miscellaneous Data Types
5) Binary Data Types
6) Bit Data Type
7) Large Object Data Types
8) Cursor Data Type
9) Rowversion Data Type
10) Sql_variant Data Type
11) Table Data Type
12) Xml Data Type
13) Uniqueidentifier Data Type
14) User-Defined Data Types
15) CLR Data Types
3.
Identity Property
4.
Internal Storage
5.
Constrains
1) Primary key
2) Foreign Key
3) Unique Key
4) Check Key
5) Default Key