将 SQL Server 2008 转换为 2000

发布于 2024-10-14 23:16:55 字数 176 浏览 1 评论 0原文

我希望将已转换为 2008 格式的数据库转换回 2000 格式。我已经尝试了 SQL Server Management Studio 中可用的所有方法。导出数据、脚本数据库等等,但都失败了。导出似乎并没有导出所需的所有内容,并且生成的脚本总是包含错误。数据库如此之大,不可能在生成的脚本中找到错误。

有没有人有什么建议。

I'm looking to convert a database that was converted to 2008 format back to 2000 format. I've tried all the methods available in SQL Server Management Studio. Export data, script database, all that, and they all fail. Export doesn't seem to export everything needed, and the generated scripts always contain errors. The database is so huge, its impossible to find the errors in the generated scripts.

Does anybody have any advice.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

陈独秀 2024-10-21 23:16:55

您将使用 SSIS/DTS(无论是向导还是手动)或 SMO 进行导出/导入。
或者使用第三方比较工具,例如 Red Gate SQL Compare

没有没有降级选项

You'll have export/import using SSIS/DTS (whether wizard or manual) or SMO.
Or use a 3rd party compare tool such as Red Gate SQL Compare

There is no downgrade option

一花一树开 2024-10-21 23:16:55

以下是与sql server数据库降级相关的链接:
http://weblogs.sqlteam.com/mladenp/archive/ 2007/02/15/60101.aspx

另外,serverfault 中有一个与此主题相关的线程:
https://serverfault.com/questions/28856/move-downgrade-database-从-sql2008-到-sql2000

Here is a link related to sql server database downgrading:
http://weblogs.sqlteam.com/mladenp/archive/2007/02/15/60101.aspx

Also, there's a thread in serverfault related to this subject:
https://serverfault.com/questions/28856/move-downgrade-database-from-sql2008-to-sql2000

花海 2024-10-21 23:16:55

您可以使用 sql 脚本生成器 提取数据库定义和数据,并在 sql 2000 中运行该脚本。

这可以从

You can use sql script generator to extract database defination and data and run that script in sql 2000.

This is easily available free of cost from http://www.sqlscriptgenerator.com/

他不在意 2024-10-21 23:16:55

也许你应该走另一个方向。在 SQL 2000 上创建一个新的空白数据库,并使用导入功能从 SQL 2008 中提取。只要 SQL 2008 数据库不使用特定于 2005/2008 的功能(它不应该使用,因为您说它是从已经2000了),那么你应该没问题。唯一的问题是导入具有依赖关系的对象时。例如,在这种情况下,请确保首先导入所有充当其他表的 FK 的 PK 的表。然后做函数。然后执行视图,因为您可能有依赖于这些视图的存储过程。然后做SP。如果您有重叠的依赖关系,您可能必须手动编写某些对象的脚本并将它们按特定顺序放置。

Maybe you should go the other direction. Create a new, blank database on SQL 2000 and use the Import feature to pull from SQL 2008. As long as the SQL 2008 database doesn't use features specific to 2005/2008 (which it shouldn't since you said it was converted from 2000 already), then you should be fine. The only issue is when importing objects that have dependencies. In this case, for example, make sure to first import all tables that act as the PK to other tables' FKs. Then do Functions. Then do Views, since you may have store procedures that depend on those views. Then do SPs. You may have to manually script certain objects and put them in a specific order if you have overlapping dependencies.

无声情话 2024-10-21 23:16:55

不幸的是,SSMS 中的生成脚本选项存在错误,在合理的时间内轻松完成此操作的唯一方法是使用第三方数据库比较或脚本工具。

除了已经提到的 SQL Compare 之外,我过去还在类似项目中使用过 ApexSQL Diff 。这些都不会出错。这两种工具都是一流的。

“生成脚本”选项创建有错误的脚本的原因是它没有考虑依赖顺序,这又回到了 sp_depends 中存在的错误。

Unfortunately there is a bug in generate scripts option in SSMS and the only way to do this easily in reasonable amount of time is to use third party database comparison or scripting tools.

Apart from SQL Compare that’s already mentioned I’ve also used ApexSQL Diff in the past for similar projects. You can’t go wrong with any of these. Both tools are top notch.

The reason Generate Scripts option creates scripts with errors is that it doesn’t take into account dependency order and that comes back to the bug that exists in sp_depends.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文