在另一个系统上重新创建数据库架构?
我可以访问远程 Oracle 数据库,该数据库的架构由可能的表组成,但没有数据。我想在本地数据库系统上重新创建此架构以进行测试。我该怎么办呢?有没有任何实用程序可以帮助解决这个问题?
另外,如果两个 Oracle 数据库版本不同,这会引起任何担忧吗?
I have access to a remote Oracle database with a schema consisting of may tables but no data. I'd like to recreate this schema on my local database system for testing purpose. How would I go about this? Are there any utilities that can help with this?
Also, if the 2 Oracle database versions are different would that be a cause of any concern?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
使用
exp
导出它,使用imp
导入它。Use
exp
to export it, andimp
to import it.正如 Paul 所说,使用 exp/imp 来执行操作。
至于您关于不同数据库版本的问题,是的,这是一个可能的问题。我假设您正在将架构从旧版本复制到新版本?确保对旧数据库使用 exp 实用程序,因为 imp 向后兼容。您可能会在尝试从较新版本转到较旧版本时遇到问题,因为您必须在较新数据库上使用较旧版本的 exp 实用程序,这可能会出现问题。
As Paul stated, use exp/imp to perform the operation.
As for your question concerning different DB versions, yes, this is a possible concern. I assume you're copying the schema from an older version to a newer one? Make sure you use the exp utility for the older database, as imp is backward compatible. You might run into problems trying to go from a newer version to an older one, as you'd have to use the exp utility from the older version on the newer DB, and that might be problematic.
如前所述,exp/imp 可以工作,并且这些应该已经在您的计算机上。我只是想补充一点,如果您使用任何第三方工具(例如,我使用 TOAD) 您的工具可能包含一些常见操作,例如“比较架构”或“创建同步脚本”等。
As stated, exp/imp will work and these should already be on your machine. I just wanted to add that if you use any third party tools (for example, I use TOAD) your tool might contain some common operations such as "Compare Schemas" or "Create Sync Script" etc.