Sql Server 创建表添加说明
http://bbs.csdn.net/topics/340184487
在此感谢

提供参考
CREATE TABLE ToPayFee
(
Id INT IDENTITY(1,1) PRIMARY KEY,
CountryID INT,
MoneyStart DECIMAL(18,2) DEFAULT(0),
MoneyEnd DECIMAL(18,2) DEFAULT(0),
Fee DECIMAL(18,2) DEFAULT(0) ,
CreateTime DATETIME DEFAULT(GETDATE()) NOT NULL,
CreatorName VARCHAR(50) NOT NULL,
Valid BIT DEFAULT(1)
FOREIGN KEY(CountryID)REFERENCES pmw_country(country_id)
)
exec sp_addextendedproperty N'MS_Description', N'主键', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'Id'
exec sp_addextendedproperty N'MS_Description', N'外键,关连国家表ID', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'CountryID'
exec sp_addextendedproperty N'MS_Description', N'开始金额', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'MoneyStart'
exec sp_addextendedproperty N'MS_Description', N'结束金额', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'MoneyEnd'
exec sp_addextendedproperty N'MS_Description', N'手续费用', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'Fee'
exec sp_addextendedproperty N'MS_Description', N'创建时间', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'CreateTime'
exec sp_addextendedproperty N'MS_Description', N'创建人', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'CreatorName'
exec sp_addextendedproperty N'MS_Description', N'是否有效(0/false无效,1/true有效)', N'user', N'dbo', N'table', N'ToPayFee', N'column', N'Valid'
Sql Server 创建表添加说明的更多相关文章
- SQL Server 创建表 添加主键 添加列常用SQL语句
--删除主键 alter table 表名 drop constraint 主键名 --添加主键 alter table 表名 add constraint 主键名 primary key(字段名1, ...
- SQL Server 创建表 添加主键 添加列常用SQL语句【转】
--删除主键alter table 表名 drop constraint 主键名--添加主键alter table 表名 add constraint 主键名 primary key(字段名1,字段名 ...
- SQL Server 创建表
SQL Server 创建表 我们在上一节中完成了数据库的创建,在本节,我们要往这个新的数据库中加入点数据,要想将数据添加到数据库,我们就必须在数据库中添加一个表,接下来来看看具体的操作. 我们的数据 ...
- SQL Server 创建表分区
原文:SQL Server 创建表分区 先准备测试表 CREATE TABLE [dbo].[Employee] ( EmployeeNo ,) PRIMARY KEY, EmployeeName ) ...
- SQL Server创建表超出行最大限制解决方法
问题的现象在创建表A的时候,出现“信息 511,级别 16,状态 1,第 5 行 无法创建大小为 的行,该值大于允许的最大值 8060.”的信息提示.很奇怪,网上查了一下,是因为要插入表的数据类型的 ...
- C#向sql server数据表添加数据源代码
HoverTree解决方案 学习C#.NET,Sql Server,WinForm等的解决方案. 本文链接http://hovertree.com/h/bjaf/0jteg8cv.htm 使用的技术. ...
- sql server 创建视图添加表时出现从其他数据库导入的表未显示出来
创建视图添加表时出现从其他数据库导入的表未显示出来,通过数据库刷新,也不能解决.关闭SQL server management studio 后,再次进入,在创建视图的时候添加表的列表就出现了新导入的 ...
- sql server创建表相关
1,设置主键的sql的三种方式 a.字段名 int primary key b.字段名 int constraint 主键名 primary key clustered(字段名) c.创建表是,后置一 ...
- SQL SERVER创建表
创建表 create table table_name ( column_name_1 data_type, column_name_2 data_type NOT NULL, column_name ...
随机推荐
- Javascript异步执行时要小心的变量作用域
function asyncFunction(callback){ setTimeout(function(){ callback() },200); } var color = 'blue'; // ...
- (3.14)mysql基础深入——mysql 日志分析工具之pt-querty-digest【待完善】
(3.14)mysql基础深入——mysql 日志分析工具之pt-querty-digest 关键字:Mysql日志分析工具.mysqlsla 常用工具 [1]mysqldumpslow:官方提供的慢 ...
- T-SQL中的十大注意事项
转载自:http://www.cnblogs.com/CareySon/archive/2012/10/11/2719598.html 1.在生产环境中不要出现Select * 这一点我想大家已经是比 ...
- mysql 数据操作 多表查询 子查询 带IN关键字的子查询
1 带IN关键字的子查询 #查询平均年龄在25岁以上的部门名关键点部门名 以查询员工表的dep_id的结果 当作另外一条sql语句查询条件使用 in (sql语句) mysql ; +-------- ...
- Unity无法创建新工程
1.解决方法 重新登录一遍账号
- [py][mx]django注册-邮件激活
人生,学习,就是一段旅途, 说是放弃,其实是自信心作祟. 因为不同时间段状态,譬如晚上和早上刚来状态不一样.做相同事情容器失去自信而放弃. 坚持可以打破这个魔咒 还有就是有些问题得分割, 不要让压死牛 ...
- C++(STL)&&树-堆结构练习——合并果子之哈夫曼树
题目题解:http://blog.csdn.net/xu12110501127/article/details/9199335 有关博客:http://www.360doc.com/content/1 ...
- PAT 1028 List Sorting[排序][一般]
1028 List Sorting (25)(25 分) Excel can sort records according to any column. Now you are supposed to ...
- [LeetCode] 232. Implement Queue using Stacks_Easy tag: Design
Implement the following operations of a queue using stacks. push(x) -- Push element x to the back of ...
- Class类的特性(上)
Class类的特性(上) ES6 的类,完全可以看作ES5构造函数的另一种写法. class Point { // ... } typeof Point // "function" ...