简体   繁体   English

SQL转换

[英]SQL Conversion

I want to port a project from sybase to oracle. 我想将一个项目从sybase移植到oracle。 I need to port the tables scripts (around 30) and some data in meta data tables(100 rows 2/3 tables). 我需要移植表脚本(大约30个)和元数据表(100行2/3表)中的一些数据。 What will the best tool for this work? 这项工作最好的工具是什么?

对于这么小的体积,您最好编写脚本而不是使用任何工具。

You do have scripts for the tables in sybase, right? 您在sybase中有用于表的脚本,对吗? Conversion by manually editing should be doable, as Dheer said. 如Dheer所说,通过手动编辑进行的转换应该是可行的。

What meta data are you referring to? 您指的是什么元数据? Is it meta data you've generated or meta data that sybase generated as a consequence ofr your DDL scripts? 是由于DDL脚本而生成的元数据还是sybase生成的元数据?

If it's meta data you've generated, you migrate it like any other data. 如果它是您生成的元数据,则可以像其他任何数据一样迁移它。

If it's system generated meta data, you are better off not to migrate it, but to adapt your usage to Oracle's meta data, stored in system tables usually referred to as the Oracle Data dictionary. 如果是系统生成的元数据,最好不要迁移它,而要使您的用法适应Oracle的元数据(存储在通常称为Oracle数据字典的系统表中)。

I believe that oracle sqldeveloper will do this. 我相信oracle sqldeveloper会做到这一点。

see http://www.oracle.com/technology/tech/migration/workbench/index_sqldev_omwb.html 参见http://www.oracle.com/technology/tech/migration/workbench/index_sqldev_omwb.html

Thanks guys... I did the conversion manually but Matt Ball is right. 谢谢大家...我是手动进行转换的,但是Matt Ball是对的。 Oracle SQl developer is a good tool. Oracle SQl开发人员是一个很好的工具。 I figured it out later.I have Version 1.5.1 installed. 我稍后才知道。我安装了1.5.1版。

But the trick is to update the extension. 但是诀窍是更新扩展名。 By default it come with only Access SQL to Oracle. 默认情况下,它仅带有Access SQL to Oracle。 Here are the steps. 步骤如下。

  1. Go to Tools>preferences>Web Browser and Proxy set your Proxy 转到工具>首选项> Web浏览器和代理设置您的代理
  2. Go to Tools>preferences>Extensions click check for Updates You should get Sybase driver and translator once you install that (Requires oracle website id and password) restart 转到“工具”>“首选项”>“扩展名”,单击“检查更新”。安装后,应重新启动Sybase驱动程序和翻译程序(需要oracle网站ID和密码)
  3. Go to Migration >Translation scratch editor should have sybase TSql drop down. 转到“迁移”>“翻译暂存器”,应将sybase TSql下拉列表。 Copy paste your scripts and enjoy... 复制粘贴您的脚本并享受...

Insert scripts you have to add Bla_Sequence.nextval by your own. 插入脚本,您必须自己添加Bla_Sequence.nextval。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM