Re: Executing pkb withing an IF ..Then statment: PLS-00103 Encountered the symbol

From: sybrandb <sybrandb_at_gmail.com>
Date: Wed, 22 Oct 2008 03:05:21 -0700 (PDT)
Message-ID: <873bfde2-cd11-4f8f-aa2b-597962c85fea@y79g2000hsa.googlegroups.com>


On 22 okt, 11:46, NGry..._at_gmail.com wrote:
> Please help,
> I am trying to create a script for patching the database.
>
> The script works with INSERT or SELECT, but when i try to execute a
> package (*pkb). I get an error: "PLS-00103 Encountered the symbol
> CREATE when expecting one of the following: begin ...."
>
> The logic is like this :
>
> varable ...
> ..
> declare ...
> begin
>
> Select c INTO a FROM test_table
>
> if :a=:b then
>
> @PG_TEST.pkb; (if in place of pkb i have simple script with INSERT or
> SELECT there are no problems)
>
> insert into test_table values((select max(id) from test_table) + 1,
> 'success');
>
> else
> ...
>
> end if;
> commit;
>
> Exception when others then
> rollback work;
> end;
> .
> /
> exit;
>
> Please help, What i am doing wrong?
>
> Thank you in advance.

It is recommended you don't post this to every forum you can spell.

--
Sybrand Bakker
Senior Oracle DBA
Received on Wed Oct 22 2008 - 05:05:21 CDT

Original text of this message