Monday, June 25, 2007

Adding a missing tab to SQL Developer

In SQL Developer v1.2 the trigger tab for views is missing. You can add this tab (and many many others you can think of) by using User Defined Extensions.

Create an XML file with the definition of the tab:

<?xml version="1.0" encoding="UTF-8"?>
  <item type="editor" node="ViewNode" vertical="true">
        <![CDATA[select table_owner
                , trigger_name
                , trigger_type
                , triggering_event
                , status
                from user_triggers
                where table_name = :OBJECT_NAME
    <subquery type="code">
      <query>         <sql><![CDATA[ select dbms_metadata.get_dll
                                ) SQL
                       from dual
Save this file and add it as an User Defined Extension of type "Editor" (using Tools / Preferences / Database / User Defined Extensions), restart SQL Developer and voilá: the trigger tab is back...