Re: Update problems ...
From: Jozef Starosta <josef_at_mars.softouch.bc.ca>
Date: 1995/07/27
Message-ID: <3v8d7t$7fm_at_mars.softouch.bc.ca>#1/1
Date: 1995/07/27
Message-ID: <3v8d7t$7fm_at_mars.softouch.bc.ca>#1/1
jack (jalford_at_immcms1.redstone.army.mil) wrote:
: Hello all,
: I am trying to update a table with the statement below, I understand the
: problem, but I don't know how to find it since the table has 60,000 rows.
: Any suggestions ??
: update ammo set serial_number= rtrim(serial_number)
: where serial_number != rtrim(serial_number);
: ERROR at line 1:
: ORA-00001: unique constraint (AMMO.PRIMARY_KEY_AMMO) violated
: - jack
Jack,
try this:
select rtrim(serial_number), count(*) from amno
group by rtrim(serial_number)
having count(*) > 1;
Hope it helps.
Jozef Received on Thu Jul 27 1995 - 00:00:00 CEST