greg.mccarty
Member²
Ok, I'm trying to compile the object type example for rectangle found in chapter 10 of the pl/sql user's guide and reference (oracle version 9.2.0.5.0)
Here it is:
CREATE OR REPLACE TYPE rectangle AS OBJECT
(
length NUMBER,
width NUMBER,
area NUMBER,
CONSTRUCTOR FUNCTION rectangle(l NUMBER, w NUMBER)
RETURN SELF AS RESULT
);
If I compile it in a package window, I get the error PLS-00658 (constructor method name must match type name) and the cursor is position on the first letter of the word FUNCTION.
If I compile it in a command window, it compiles fine.
Anyone know why this happens?
I'm using plsql dev version 6.0.5.931
Here it is:
CREATE OR REPLACE TYPE rectangle AS OBJECT
(
length NUMBER,
width NUMBER,
area NUMBER,
CONSTRUCTOR FUNCTION rectangle(l NUMBER, w NUMBER)
RETURN SELF AS RESULT
);
If I compile it in a package window, I get the error PLS-00658 (constructor method name must match type name) and the cursor is position on the first letter of the word FUNCTION.
If I compile it in a command window, it compiles fine.
Anyone know why this happens?
I'm using plsql dev version 6.0.5.931