Hello!
I don’t know if it is a bug or feature, but… I have created a function in Oracle and added it to ora7en.prm file. Then I have created an object using this function (just MyFunction(ColumnInSomeTable),
nothing complicated) and when tried to parse it, I got “Invalid column name” from Oracle.
Nevertheless, I can add this object to a report and it works just fine…
Anyone seen this? Is it normal?
Ryszard Mikke
PS. BO is 4.1.2a and Oracle is 4.2.3 if this matters…
Yes, this is normal. To PARSE an object, BO needs to know what table the object belongs to, but a function does not have a table – BO needs to build a SELECT statement, but you’ve left the FROM clause blank, so the PARSE fails.
The only impact in Reporter would be if you try to build a query with a single object – this function object. Then BO will have the same problem – BO can’t build a SELECT statement. As long as you specify one other object (ie, one other TABLE) in your query, you’ll be fine…
But why??
The object is, as stated below, MyFunction(ColumnInSomeTable) - so there is a table and column name
explicitly given in the argument??? The select should be just
select MyFunction(ColumnInSomeTable)
from SomeTable
and the same goes for multi-parameter functions. There should only be a problem if really no
table is used in an object…
Yes, this is normal. To PARSE an object, BO needs to know what table the object belongs to, but a function does not have a table – BO needs to build
a SELECT statement, but you’ve left the FROM clause blank, so the PARSE fails.
The only impact in Reporter would be if you try to build a query with a single object – this function object. Then BO will have the same problem – BO can’t build a SELECT statement. As long as you specify one other object (ie, one other TABLE) in your query, you’ll be fine…
I don’t know if it is a bug or feature, but… I have created a function in Oracle and added it to ora7en.prm file. Then I have created an object using this function (just MyFunction(ColumnInSomeTable),
nothing complicated) and when tried to parse it, I got “Invalid column name”
from Oracle.
Nevertheless, I can add this object to a report and it works just fine…
Anyone seen this? Is it normal?
Ryszard Mikke
PS. BO is 4.1.2a and Oracle is 4.2.3 if this matters…