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

Home -> Community -> Mailing Lists -> Oracle-L -> Problems with PL/SQL - URGENT

Problems with PL/SQL - URGENT

From: Jorge Luiz Alves <jalves_at_mdic.gov.br>
Date: Tue, 18 Jul 2000 17:41:01 -0300
Message-Id: <10562.112320@fatcity.com>


Hi all,

I have a pl/sql block that declare a cursor for read a view = ALL_TAB_COLUMNS.
The select statement that form cursor, runs at sqlplus and doesn=B4t = works in
the storage procedure, that is my problem. I=B4m running the procedure = with
owner.

Please give a look in my procedure:

procedure pr_charge_data as

     cursor find_tabs_c is
            select table_name, column_name
              from all_tab_columns
             where owner =3D 'TEST' and
                   table_name  like 'AGREG%' and
                   column_name like 'ID%'   and
                   column_name not in ('ID_TITLE','ID_ECONOMIC_BLOCK')
           order by column_id;=20
     wtable varchar2(30);
     wcol   varchar2(30);
begin
     open find_tabs_c;
     loop
        fetch find_tabs_c into wtable,wcol;
        if find_tabs_c%NOTFOUND then
           dbms_output.put_line('*** end ***');
           exit;
        end if;
        dbms_output.put_line(wtable);
     end loop;
     close find_tabs_c;

end;

THE RESULT IS: *** end ***, when i execute SP.

and when i run de sql statement it brings all the record that attempt = the
conditions in where clause; Received on Tue Jul 18 2000 - 15:41:01 CDT

Original text of this message

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