[英]Scripting Oracle database : all objects from selected schemas
Currently we are using Oracle SQL Developer for scripting all objects from selected schemas. 当前,我们正在使用Oracle SQL Developer来编写所选模式中的所有对象的脚本。 But this is very uncomfortable solution, since we should select schema, search for all objects, select all objects and move all selected objects to the list.
但这是非常不舒服的解决方案,因为我们应该选择架构,搜索所有对象,选择所有对象并将所有选定的对象移动到列表中。 And each step is time expensive.
而且每个步骤都耗费时间。 And repeat it 12 times (12 shcemas should be exported).
并重复12次(应导出12个shcemas)。
Is it possible to improove export dialog through Oracle SQL Developer plugins? 是否可以通过Oracle SQL Developer插件改善导出对话框? Or may by the better way is to use shell/command prompt utilty for scripting Oracle DB... Which utility to use?
或者,也许更好的方法是使用外壳程序/命令提示符实用工具来编写Oracle DB脚本...要使用哪个实用工具?
Use SQLcl! 使用SQLcl!
Write some javascript, take advantage of built in SPOOL and DDL commands. 编写一些JavaScript,利用内置的SPOOL和DDL命令。 Much faster than using our GUIs.
比使用我们的GUI快得多。
Example here (from Kris ) - and it actually goes through ALL_OBJECTS https://gist.github.com/krisrice/de6f694b5241682059968bd5beadbcf7 这里的例子(来自Kris )-实际上它通过ALL_OBJECTS https://gist.github.com/krisrice/de6f694b5241682059968bd5beadbcf7
SQLcl uses the same code base as SQL Developer, but it's a command line interface and it offers client side scripting so you can do things like loop through a set of objects and interact with the OS. SQLcl使用与SQL Developer相同的代码库,但是它是一个命令行界面,并且提供了客户端脚本,因此您可以执行诸如遍历一组对象并与OS交互的操作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.