Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法为 SQL Server Management Studio 中的表获取“脚本表为”>“创建到”选项以保留为每列设置的排序规则类型?
我知道在创建表时可以为列指定排序规则类型,所以我觉得奇怪的是这些设置不存在于 SSMS 的脚本输出中。
转到工具-> 选项。
展开“Sql Server 对象资源管理器”-> 脚本,您可以在“表和视图选项”类别中启用“包含排序规则”选项(默认值为 false)。
在 Management Studio 中右键单击数据库 ---> 任务 --> 生成脚本。
在向导的最后一页有一个高级按钮,它有很多选项,其中一个是脚本排序。