Send query values to a table [message #374377] |
Fri, 08 June 2001 13:05 |
Srikanth Tutukuri
Messages: 3 Registered: June 2001
|
Junior Member |
|
|
I am trying to send the results of a query into a table. The sql statement is as follws.
Select OL_ID, OL_NAME into BestSellers from Orders;
where BestSellers is the name of the temporary table. I have not created the table BestSellers before. Do we need to create a table before we can insert data into it or can we send the data from a query result into a temporary table. Can anyone help me on this. Any help is highly appreciated.
|
|
|
|
Re: Send query values to a table [message #375206 is a reply to message #374377] |
Sat, 04 August 2001 05:50 |
hisham
Messages: 4 Registered: August 2001
|
Junior Member |
|
|
Do the following way to insert records into
your temporary table.
Step 1,
CREATE GLOBAL TEMPORARY TABLE BestSellers
(OL_ID VARCHAR2(15), OL_NAME VARCHAR2(35))
Step 2,
Select OL_ID, OL_NAME into BestSellers from Orders
|
|
|