Re: Pro*C compiler error calling stored function

From: Houston Keach <ahkNOSPAM_at_hji.com>
Date: Fri, 14 Jan 2000 22:06:11 GMT
Message-ID: <387f9d62.28657206_at_news.evansville.net>


The syntax should be something like this:

  EXEC SQL EXECUTE
    BEGIN
      :myreturn := myfunc(:myparam);
    END;
  END-EXEC; On Wed, 12 Jan 2000 18:11:06 +0100, "EA" <appshome_at_geocities.com> wrote:

>The Oracle Pro*C precompiler (Pro*C/C++: Release 8.0.4.0.0 on Sun Solaris
>2.6) doesn't seem to like the following syntax for calling a stored
>function:
>
>EXEC SQL CALL myfunc(:myparam) INTO :myreturn;
>
>The error message is
>
>PCC-S-02201, Encountered the symbol "CALL" when expecting one of the
>following:
>
> for, at, close, commit, connect, declare, describe, execute,
> fetch, open, prepare, rollback, select, whenever, alter,
> audit, comment, create, delete, drop, grant, insert, lock,
> noaudit, rename, revoke, set, update, validate, arraylen,
> allocate, cache, context, enable, free, object, savepoint,
> analyze, explain, truncate,
>The symbol "alter," was substituted for "CALL" to continue.
>
>According to the manuals (I only have Oracle 8i manuals at hand but I don't
>suppose this has changed from release 8.0x to release 8.1x) this syntax
>should be just fine.
>
>After the precompiler substitutes "alter" for "CALL" everything goes
>downhill, of course, with follow up errors like
>
>PCC-S-02206, Host variables are not permitted within a DDL statement
>
>Any ideas what I'm doing wrong? To reproduce this behaviour just add the
>offending line plus some host variable declarations to sample1.pc that comes
>with Pro*C.
>
>Any help would be greatly appreciated.
>
>Cheers
>E.
>
>
>
>
>
>

Houston Keach
Tacit Solutions, Inc. Received on Fri Jan 14 2000 - 23:06:11 CET

Original text of this message