Unanswered: Creating Temporary Tables in stored procedures
While working with the Oracle Migration Workbench for migrating the SQL Server database to Oracle 8i, I encountered with these problems.
1> In SQL Server we had created some procedures in which we are creating some TEMPORARY TABLES n at the end of procedures just return the recordset from that stored procedure and after that we just simply drop that temporary tables. My problem is this that how we will incorporate the same functionality in the Oracle stored procedures.
As I had searched for this I come to know that we can create the temporary tables with the
execute immediate 'create global temporary table A <definition follows> ';
but with these we can create the temporary tables for the session and even after the session it only delete all the records but not the defination of temporary tables. Secondly with the each execution of the parent stored procedure it will create that table or simply bypass the create table statement if find the defination of the table.....
2> Another problem which I get during migration is there is a problem in converting this query, I simply unable to understand that what the problem is????
SELECT * from discom_consumer as i
where i.name_e like ltrim(@name) and
i.address1 like ltrim(@add1) and
i.address2 like ltrim(@add2) and
i.address3 like ltrim(@add3)
The errors comes with the LIKE operator..
Please any one can help....
Thanking you in anticipation.