se.cartao);
Hope this makes sense,
~p
-Original Message-
*From:* [EMAIL PROTECTED] [mailto:
[EMAIL PROTECTED] *On Behalf Of *Ezequias Rodrigues da Rocha
*Sent:* Monday, 26 February 2007 10:58
*To:* Phillip Smith
*Cc:* pgsql-sql@postgresql.org
*Subject:* Re: [SQL] Insert based in a select
] [mailto:[EMAIL PROTECTED]
On Behalf Of Ezequias Rodrigues da Rocha
Sent: Monday, 26 February 2007 10:58
To: Phillip Smith
Cc: pgsql-sql@postgresql.org
Subject: Re: [SQL] Insert based in a select
The second statement works but only 1 row was affected. It do not apply to
me.
The first statement i
*From:* Ezequias Rodrigues da Rocha [mailto:[EMAIL PROTECTED]
*Sent:* Monday, 26 February 2007 00:43
*To:* [EMAIL PROTECTED]
*Subject:* Re: [SQL] Insert based in a select
Phillip,
Thank you for the information but the master (id) is only a field of my
secondary table.
My sql statement is like this
~p
-Original Message-
From: Ezequias Rodrigues da Rocha [mailto:[EMAIL PROTECTED]
Sent: Monday, 26 February 2007 00:43
To: [EMAIL PROTECTED]
Subject: Re: [SQL] Insert based in a select
Phillip,
Thank you for the information but the master (id) is only a field of my
secondary ta
INSERT INTO second_table (master_id) SELECT id FROM master_table ORDER
BY id;
Was it important to you that the id and master id in the second table
match up? ie, 1 and 10, 2 and 20, 3 and 30 - not 1 and 30, 2 and 10, 3
and 20 etc...
~p
On Sat, 2007-02-24 at 21:06 -0300, Ezequias Rodrigues da Roc