读书笔记:Sams Teach Yourself Microsoft® SQL Server T-SQL in 10 Minutes

  • what is database:a simple metaphor, a database is a container, such as file cabinet,  which stores data in an organized way.
  • caution: database is not database software which is called database management system (DBMS). people use dbms to manipulate database.
  • table: all data in cabinet are recorded in tables, which is a structured list of data of a specific type.
  • schema: information about database and table layout and properties.
  • column = field = 字段 = 列
  • row = record = 记录 = 行
  • about key: no two rows in a table have same primary key value; every row must have a primary key, and the primary key can not be NULL.
  • 主键可以有一个,也可以多个。
  • do not update values of primary key
  • do not reuse values of primary key
  • SQL is a universal language to manipulate DBMS, but in fact, there is no DBMS verdors use the identical SQL.
  • SQL Server提供180天的试用版,SQL Express版是免费的,我们还有什么使用盗版的理由?
  • use:使用数据库;
  • sp_databases:列出可用数据库;
  • sp_tables:列出当前数据库中所有表;
  • sp_tables null, dbo, database_name, "'table'":只列出table,而非view,或system table
  • sp_columns table_name:列出表解构
  • identity是什么:系统自动生成的id
  • sp_server_info:显示当前server信息
  • sp_spaceused:显示已用空间

你可能感兴趣的:(class_Mem)