Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Rollback after truncate?? + 2 more questions :-)

RE: Rollback after truncate?? + 2 more questions :-)

From: Kevin Lange <kgel_at_ppoone.com>
Date: Wed, 15 Aug 2001 14:43:14 -0700
Message-ID: <F001.0036C2EE.20010815144351@fatcity.com>

  1. No.
  2. I do not think its a function of the number of words. DDL needs the Execute Immediate.
  3. Don't Know. Need to see the function.

-----Original Message-----
Sent: Wednesday, August 15, 2001 5:08 PM To: Multiple recipients of list ORACLE-L

Hi,

1.Can I rollback after doing a truncate table (it seems to me that I can' t) e.g.

       Execute Immediate 'Truncate Table '|| TablaNevTomb(i);

       Execute Immediate
          'Begin '||
            'Insert into '|| TablaNevTomb(i) ||' (Select * From 
X$_'||TablaNevTomb(i)||');'||
          'End;';

     Exception
       When others Then RollBack

2. Is there a way to use a command with more than one word in Pl/Sql without using it dynamically?

For example I can use "Truncate table" only with Execute immediate within a Pl/Sql block.

3. I have a statement in a package:

  Insert into A

     ( Select Col1 ,MyFunction(Col1)
         from B );

If the MyFunction function is made with "create or replace function" everything works perfectly,
but if the same function is declared within the package, I get the error message:
PLS-00231 function 'string' may not be used in SQL

Thank you for your help

Zsolt Csillag
Hungary

--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author: Csillag Zsolt
  INET: starsoft_at_interware.hu

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).

--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author: Kevin Lange
  INET: kgel_at_ppoone.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Wed Aug 15 2001 - 16:43:14 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US