Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Insert/Select command returns too many values error

Insert/Select command returns too many values error

From: Harold Gray <hgray_at_pcisys.net>
Date: Tue, 05 May 1998 10:40:23 -0600
Message-ID: <354F40F6.10AB0ADC@pcisys.net>


I'm new to the Oracle arena and am having problems with an insert/select statment.
The following commands are an attempt to insert string literals into table "location" only
after a match is found for company_id (a sequence #) in a table called company.
The owner of the table is user msi.

insert into msi.location (

    company_id,
    name,
    addr1,
    addr2,
    city,
    state,
    zip,
    country )
select id,

'Houston Headquarters',
'123 Anyplace Dr.'
'',
'Houston',
'TX',
'77042',
'USA'

from msi.company where company.name = 'CompanyName';

When this is ran I receive a ORA-00913 too many values error under Oracle 8.0

remove the no spam to reply

Thanks in advance for your insight

Harold Gray Received on Tue May 05 1998 - 11:40:23 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US