<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Creating synonym inside a procedure in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-synonym-inside-a-procedure/m-p/2850750#M825922</link>
    <description>I may be mistaken but as far as i know, you cannot execute DDL statements inside a stored procedure without the use of the oracle supplied utility DBMS_SQL or the statement EXECUTE IMMEDIATE.&lt;BR /&gt;&lt;BR /&gt;It is worth a check at &lt;A href="http://metalink.oracle.com/" target="_blank"&gt;http://metalink.oracle.com/&lt;/A&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;Kim&lt;BR /&gt;</description>
    <pubDate>Mon, 25 Nov 2002 19:28:46 GMT</pubDate>
    <dc:creator>Kimathi Njeru</dc:creator>
    <dc:date>2002-11-25T19:28:46Z</dc:date>
    <item>
      <title>Creating synonym inside a procedure</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-synonym-inside-a-procedure/m-p/2850748#M825920</link>
      <description>I tried to create a private synonym(on another schema) with a procedure but it throws a"insufficient previliges" error. But when I execute the cmd in SQL prompt it works. Here is my procedure..&lt;BR /&gt;&lt;BR /&gt;create or replace procedure grant_read&lt;BR /&gt;as&lt;BR /&gt;       cursor T1cursor IS&lt;BR /&gt;            select tname&lt;BR /&gt;            from tab;&lt;BR /&gt;       tname tab.tname%type;&lt;BR /&gt;&lt;BR /&gt;begin&lt;BR /&gt;&lt;BR /&gt;        open T1cursor;&lt;BR /&gt;&lt;BR /&gt;        loop&lt;BR /&gt;                FETCH T1cursor into tname;&lt;BR /&gt;&lt;BR /&gt;                exit when T1cursor%NOTFOUND;&lt;BR /&gt;&lt;BR /&gt;                execute immediate 'create synonym gisreader.' || tname || ' for ' || tname;&lt;BR /&gt;/*              execute immediate 'grant select on ' || tname || ' to gisreader'; */&lt;BR /&gt;&lt;BR /&gt;        end loop;&lt;BR /&gt;&lt;BR /&gt;        close T1cursor;&lt;BR /&gt;&lt;BR /&gt;end;&lt;BR /&gt;&lt;BR /&gt;Thanx much for the help!!!!!!&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Parthiban</description>
      <pubDate>Sun, 24 Nov 2002 01:53:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-synonym-inside-a-procedure/m-p/2850748#M825920</guid>
      <dc:creator>Parthiban Dhananjeyan</dc:creator>
      <dc:date>2002-11-24T01:53:42Z</dc:date>
    </item>
    <item>
      <title>Re: Creating synonym inside a procedure</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-synonym-inside-a-procedure/m-p/2850749#M825921</link>
      <description>As the system or sys user, grant the "create synonym" privilege directly to the user.  The reason for this is that procedures cannot inherit privileges from roles.  It should work normally after that.&lt;BR /&gt;&lt;BR /&gt;Brian</description>
      <pubDate>Sun, 24 Nov 2002 18:32:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-synonym-inside-a-procedure/m-p/2850749#M825921</guid>
      <dc:creator>Brian Crabtree</dc:creator>
      <dc:date>2002-11-24T18:32:33Z</dc:date>
    </item>
    <item>
      <title>Re: Creating synonym inside a procedure</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-synonym-inside-a-procedure/m-p/2850750#M825922</link>
      <description>I may be mistaken but as far as i know, you cannot execute DDL statements inside a stored procedure without the use of the oracle supplied utility DBMS_SQL or the statement EXECUTE IMMEDIATE.&lt;BR /&gt;&lt;BR /&gt;It is worth a check at &lt;A href="http://metalink.oracle.com/" target="_blank"&gt;http://metalink.oracle.com/&lt;/A&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;Kim&lt;BR /&gt;</description>
      <pubDate>Mon, 25 Nov 2002 19:28:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-synonym-inside-a-procedure/m-p/2850750#M825922</guid>
      <dc:creator>Kimathi Njeru</dc:creator>
      <dc:date>2002-11-25T19:28:46Z</dc:date>
    </item>
  </channel>
</rss>

