Environment: XE 10g, WinXP SP2
As described in another thread, I'm trying to get a PHP application to run against an Oracle database. In that application it tries to run a few CREATE TYPE statements. Those statements are failing with "ORA-24344: success with compilation error".
The failing statement is:
create or replace type BIT_OR_IMPL as object (
val NUMBER,
static function ODCIAggregateInitialize(sctx IN OUT BIT_OR_IMPL)
return number,
member function ODCIAggregateIterate(self IN OUT BIT_OR_IMPL,
value IN number) return number,
member function ODCIAggregateTerminate(self IN OUT BIT_OR_IMPL,
returnValue OUT number, flags IN number) return number,
member function ODCIAggregateMerge(self IN OUT BIT_OR_IMPL,
ctx2 IN BIT_OR_IMPL) return number
)
I'm new to Oracle, but that statement appears to be syntactically OK... balanced parentheses, etc.
Then I took that statement and tried to run it in a SqlPlus script:
g2user/g2pwd
set echo on;
drop type BIT_OR_IMPL;
create type BIT_OR_IMPL;
--create or replace type BIT_OR_IMPL as object ( val NUMBER, static function ODCIAggregateInitialize(sctx IN OUT BIT_OR_IMPL) return number, member function ODCIAggregateIterate(self IN OUT BIT_OR_IMPL, value IN number) return number, member function ODCIAggregateTerminate(self IN OUT BIT_OR_IMPL, returnValue OUT number, flags IN number) return number, member function ODCIAggregateMerge(self IN OUT BIT_OR_IMPL, ctx2 IN BIT_OR_IMPL) return number );
commit;
quit;
But for some reason SqlPlus just sits there expecting more input:
C:\MyServer>sqlplus @temp.sql
SQL*Plus: Release 10.2.0.1.0 - Production on Thu Mar 23 00:00:29 2006
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
SQL>
SQL> drop type BIT_OR_IMPL;
Type dropped.
SQL>
SQL> create type BIT_OR_IMPL;
2 --create or replace type BIT_OR_IMPL as object ( val NUMBER, static functio
n ODCIAggregateInitialize(sctx IN OUT BIT_OR_IMPL) return number, member functio
n ODCIAggregateIterate(self IN OUT BIT_OR_IMPL, value IN number) return number,
member function ODCIAggregateTerminate(self IN OUT BIT_OR_IMPL, returnValue OUT
number, flags IN number) return number, member function ODCIAggregateMerge(self
IN OUT BIT_OR_IMPL, ctx2 IN BIT_OR_IMPL) return number );
3
4 commit;
5
6 quit; // <-- It hangs here until I kill it with Ctrl-C, then it continues
7
8 Disconnected from Oracle Database 10g Express Edition Release 10.2.0.1.0 -
Production
C:\MyServer>
I even trimmed down the CREATE TYPE statement to almost nothing, and it always hangs.
Is there a problem here, or am I doing something wrong?
Thanks.