摘要:
use test -- 查询数据库中所有的表和架构名称select SCHEMA_NAME(schema_id) as table_schema_name, name as table_name from sys.tables; select table_schema,table_name from 阅读全文
摘要:
With ties 语句是与top、order by 语句联合使用的语句;我们在实际查询过程中会遇到这样的情况,比如查询考试为前三名的学生信息,发现有并列第三的情况,如果我们只是top 3 发现并列第三的学生信息有的没有显示出来,基于这种情况我们就需要结合with ties 语句进行查询。With 阅读全文
摘要:
CREATE DATABASE Test use Test --创建用户类型表CREATE TABLE UserType ( ID INT NOT NULL identity(1,1) primary key, TypeName VARCHAR(200) DEFAULT NULL , TypeDes 阅读全文