1、powerdesigner 设置默认值。
用工具打开表,找到Columns,然后选中你要修改的字段值,点属性。

找到Standard Checks,default选择即可。如下图:

2、设置不为空约束等。
如下图:
在Column Properties对话框中勾选“mandatory”就是not null。

写SQL,(MSSQL) -加字段,设约束
alter table teacher add sex int not null default 0;
本文详细介绍了如何使用PowerDesigner设置默认值和不为空约束,包括通过工具界面操作和编写SQL实现的方法。
1、powerdesigner 设置默认值。
用工具打开表,找到Columns,然后选中你要修改的字段值,点属性。

找到Standard Checks,default选择即可。如下图:

2、设置不为空约束等。
如下图:
在Column Properties对话框中勾选“mandatory”就是not null。

写SQL,(MSSQL) -加字段,设约束
alter table teacher add sex int not null default 0;

被折叠的 条评论
为什么被折叠?