Is it possible to use "SELECT * FROM MyFunction()" syntax in Oracle for Pipelined Functions?

954 views Asked by At

Is it possible to call an Oracle Pipelined Function without specifying TABLE( ) operator, like in the following example?

SELECT * FROM MyFunction()

I don't want to use the following, due to compatibility with SqlServer.

SELECT * FROM TABLE( MyFunction() )

Can anyone help me, please?

Thank you!

1

There are 1 answers

4
Elisheva Wasserman On

First, table function is not a good idea in Oracle, since it loads all the data to the memory, and no indexes will be used in your query any more.

Second, table functions work totaly differerent in SQL Server & Oracle, My best suggestion is to use dynamicSql, the function will build sql string and return it and the main procedure will execute it, should work in oracle and sql server as well.