Oracle equivalence for SqlServer #temp_table? [message #370412] |
Wed, 22 September 1999 12:16 |
paulg
Messages: 2 Registered: September 1999
|
Junior Member |
|
|
In SqlServer Stored Procedures you can specify a temporary table that is unique to the current connection.
Select emp_dept_key into #temp_emp from Employee where emp_hire_date > '1/1/1999'
select dept_name from department, #temp_emp
where dept_key = emp_dept_key
Is a trivial example. How can this be done in Oracle?
Thanks, Paul
|
|
|
|
Re: Oracle equivalence for SqlServer #temp_table? [message #370420 is a reply to message #370412] |
Wed, 22 September 1999 15:50 |
MikeG
Messages: 14 Registered: August 1999
|
Junior Member |
|
|
Oracle does not have the same temp table facility as Sybase but having written procs in both DB's i prefer Oracle. Oracle has more functions available (such as a decode) and better cursor handling functions.
Oracle does have 'tables' that are like arrays but you cannot run SQL against them.
If you still need a way around it submit the example and maybe we can suggest an Oracle equivalent.
|
|
|
Re: Oracle equivalence for SqlServer #temp_table? [message #370422 is a reply to message #370412] |
Wed, 22 September 1999 17:03 |
paulg
Messages: 2 Registered: September 1999
|
Junior Member |
|
|
Thanks for trying. Yes I know Oracle is Industrial strength and more capable than SQlServer, yes I know this example could be joined. My question still remains is there a way to create a table that is unique to the connection for temp storage. It's offen much better performance for one thing to stage queryies but in any case is there a solution for this or what is the best work around?
Thanks, Paul
|
|
|