pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Getting more than one row in UNIQUE fields
3+ messages / 3 participants
[nested] [flat]

* Getting more than one row in UNIQUE fields
@ 2009-12-04 17:24  Another Trad <anothertrad@gmail.com>
  0 siblings, 2 replies; 3+ messages in thread

From: Another Trad @ 2009-12-04 17:24 UTC (permalink / raw)
  To: pgsql-sql

My table 'client' has the unique 'client_id'.
My test server, when I try:
select * from client where client_id = 12
My server returns 3 rows!!!!
When I try to update this client, his name for example,using my framework
(SQLAlchemy), obviously returns the error:
"Updated rowcount 3 does not match number of objects updated 1"
But the field client_id is unique and has a sequence to auto increment.

Anyone ever pass to this?

^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Getting more than one row in UNIQUE fields
@ 2009-12-04 17:36  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Another Trad <anothertrad@gmail.com>
  1 sibling, 0 replies; 3+ messages in thread

From: Tom Lane @ 2009-12-04 17:36 UTC (permalink / raw)
  To: Another Trad <anothertrad@gmail.com>; +Cc: pgsql-sql

Another Trad <anothertrad@gmail.com> writes:
> My table 'client' has the unique 'client_id'.
> My test server, when I try:
> select * from client where client_id = 12
> My server returns 3 rows!!!!

We've seen bugs of that sort in the past ... what PG version is this,
and on what platform?

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Getting more than one row in UNIQUE fields
@ 2009-12-06 08:55  Jasen Betts <jasen@xnet.co.nz>
  parent: Another Trad <anothertrad@gmail.com>
  1 sibling, 0 replies; 3+ messages in thread

From: Jasen Betts @ 2009-12-06 08:55 UTC (permalink / raw)
  To: pgsql-sql

On 2009-12-04, Another Trad <anothertrad@gmail.com> wrote:
> --001485f94df095921c0479ea62fd
> Content-Type: text/plain; charset=ISO-8859-1
>
> My table 'client' has the unique 'client_id'.
> My test server, when I try:
> select * from client where client_id = 12
> My server returns 3 rows!!!!

I had similar with a client on friday, windows event log shouwed disk
errors, chkdsk showed damaged database files.

I passed the problem back to their IT guy.



^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2009-12-06 08:55 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2009-12-04 17:24 Getting more than one row in UNIQUE fields Another Trad <anothertrad@gmail.com>
2009-12-04 17:36 ` Tom Lane <tgl@sss.pgh.pa.us>
2009-12-06 08:55 ` Jasen Betts <jasen@xnet.co.nz>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox