Importing SQL and XQuery templates

In addition to adding new templates by using the New Template window, you can import existing SQL and XQuery templates through the SQL and XQuery Editor - Templates page of the Preferences window.
You can import into your workbench SQL and XQuery templates that members of your team create in their workbench and then export. The XML file that contains the exported SQL and XQuery templates has the following syntax. If the file contains more than one template, each template is represented by one <template> element.
<?xml version="1.0" encoding="UTF-8"?>
<templates>
   <template autoinsert="false" context="sql" deleted="false"
             description="your_template_description" enabled="true"
             name="your_template_name">your_template_pattern</template>
</templates>
The value for the autoinsert attribute can be true or false. The value for the context attribute is sql or xquery, depending on the type of template that was exported.

To import an SQL or XQuery template:

  1. Select Window > Preferences.
  2. In the Preferences window, select Data Management > SQL Development > SQL and XQuery Editor > Templates.
  3. On the Templates page, click Import, and then browse to and select the file that contains the template that you want to import. The template in the imported template file is added to the list of templates on the SQL and XQuery Editor - Templates page
  4. Click OK in the Preferences window.
The imported template is available in your workbench for you to use in the SQL and XQuery editor.
Related tasks
Exporting SQL and XQuery templates
Related reference
Preferences window - SQL and XQuery Editor - Templates page

Feedback