inserting values into table [message #38531] |
Wed, 24 April 2002 19:00 |
Sid
Messages: 38 Registered: May 1999
|
Member |
|
|
I want to insert values into an ord table.
The values I want are in the item table they range from 600 and 699. These values are in ORACLE demo.
insert into ord( ordid, itemid, prodid, actualprice, qty, itemtot)
select * from demo.item
where item.ordid between 600 AND 699;
*
ERROR at line 3:
ORA-00904: invalid column name
|
|
|
Re: inserting values into table [message #38535 is a reply to message #38531] |
Thu, 25 April 2002 06:02 |
Epe
Messages: 99 Registered: March 2002
|
Member |
|
|
Hello,
I suppose that "demo" is a schema ?
If so, I don't think you should use "item.ordid" in the where clause. You could try with "demo.item.ordid", but it will surely work if you use an alias for the table demo.item :
"insert into ord(ordid,itemid,prodid,acutalprice,qty,itemtot)
select * from demo.item di
where di.ordid between 600 and 699;"
AND if you have rights to select on the demo schema...
Success,
epe
|
|
|