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 -> Re: Insert Statement

Re: Insert Statement

From: Daniel Morgan <damorgan_at_exxesolutions.com>
Date: Thu, 28 Aug 2003 09:37:36 -0700
Message-ID: <3F4E2FD0.1D64DA47@exxesolutions.com>


Onismus Radebe wrote:

> "Tony Rees" <antonie.rees_at_btinternet.com> wrote in message
> news:bil326$70m$1$8302bc10_at_news.demon.co.uk...
> > Thanks for the suggestion. I tried this and it did not work. It came back
> > with an ora-00947 Not enough values
> >
> > cheers
> >
> > Tony
> >
> > "sjacek" <member29683_at_dbforums.com> wrote in message
> > news:3295459.1062077864_at_dbforums.com...
> > >
> > > insert into B select * from A;
> > >
> > >
> [snip]

>

> Does table A and B have the same structure in particular the same number of
> columns? I guess that could be the cause of the problem.
>

> --
> Onismus \|/
> o o
> __________________________________oOO_(_)_OOo______________________________
>
> E-Business and Information Management | God said ...
> Knowledge Discovery & Dissemination | 1. div D = p
> | 2. curl E = -dB/dt
> Tel: +27 11 350 3414 | 3. div B = 0
> Fax: +27 11 350 8585 | 4. curl H = dD/dt + J
> Cel: +27 83 591 5310 | ... and there was light.
> ___________________________________________________________________________
Obviously not. Tony ... if you want help you are going to have to put in some effort. For example, give us the table structures. If as Onismus suggests, and I concur, the two tables don't have the same structure you can use NULL or a placehold for missing columns. For example: INSERT INTO a SELECT field1, field2, NULL, field3, NULL, field4, field5, 'XXX', field6
FROM b;
--
Daniel Morgan
http://www.outreach.washington.edu/extinfo/certprog/oad/oad_crs.asp
http://www.outreach.washington.edu/extinfo/certprog/aoa/aoa_main.asp
damorgan_at_x.washington.edu
(replace 'x' with a 'u' to reply)
Received on Thu Aug 28 2003 - 11:37:36 CDT

Original text of this message

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