Thread: Need help

Need help

From
"Chris White (cjwhite)"
Date:
I am running 7.4.2 and I am seeing a strange error. I am using jdbc to update a table with the following statement:
 
update vm_message set usecount=4 where messsage id='1234567';
 
this statements generates a PSQLException with the following message:
 
ERROR: duplicate key violates unique constraint "vm_message_pkey"
 
I don't understand why I am getting this message because the primary key for table vm_message is messageid and this is not being changed
 
Any body have any ideas?
 
Chris White

Re: Need help

From
"Joshua D. Drake"
Date:
> ERROR: duplicate key violates unique constraint "vm_message_pkey"
>
> I don't understand why I am getting this message because the primary key
> for table vm_message is messageid and this is not being changed
>
> Any body have any ideas?

7.4.2 is know to have index issues. Try reindexing the primary key and
executing the query again.

Sincerely,

Joshua D. Drake


>
> Chris White


--
Command Prompt, Inc., home of PostgreSQL Replication, and plPHP.
Postgresql support, programming shared hosting and dedicated hosting.
+1-503-667-4564 - jd@commandprompt.com - http://www.commandprompt.com
Mammoth PostgreSQL Replicator. Integrated Replication for PostgreSQL

Attachment

Re: Need help

From
"Chris White (cjwhite)"
Date:
That doesn't help me because this is running in an embedded system that
should have little or no db admin. Anybody suggest what version I should be
running?

Chris

-----Original Message-----
From: Joshua D. Drake [mailto:jd@commandprompt.com]
Sent: Wednesday, October 20, 2004 12:42 PM
To: cjwhite@cisco.com
Cc: pgsql-admin@postgresql.org
Subject: Re: [ADMIN] Need help

> ERROR: duplicate key violates unique constraint "vm_message_pkey"
>
> I don't understand why I am getting this message because the primary
> key for table vm_message is messageid and this is not being changed
>
> Any body have any ideas?

7.4.2 is know to have index issues. Try reindexing the primary key and
executing the query again.

Sincerely,

Joshua D. Drake


>
> Chris White


--
Command Prompt, Inc., home of PostgreSQL Replication, and plPHP.
Postgresql support, programming shared hosting and dedicated hosting.
+1-503-667-4564 - jd@commandprompt.com - http://www.commandprompt.com
Mammoth PostgreSQL Replicator. Integrated Replication for PostgreSQL


Re: Need help

From
"Joshua D. Drake"
Date:
Chris White (cjwhite) wrote:
> That doesn't help me because this is running in an embedded system that
> should have little or no db admin. Anybody suggest what version I should be
> running?

7.4.5.

Sincerely,

Joshua D. Drake


>
> Chris
>
> -----Original Message-----
> From: Joshua D. Drake [mailto:jd@commandprompt.com]
> Sent: Wednesday, October 20, 2004 12:42 PM
> To: cjwhite@cisco.com
> Cc: pgsql-admin@postgresql.org
> Subject: Re: [ADMIN] Need help
>
>
>>ERROR: duplicate key violates unique constraint "vm_message_pkey"
>>
>>I don't understand why I am getting this message because the primary
>>key for table vm_message is messageid and this is not being changed
>>
>>Any body have any ideas?
>
>
> 7.4.2 is know to have index issues. Try reindexing the primary key and
> executing the query again.
>
> Sincerely,
>
> Joshua D. Drake
>
>
>
>>
>>Chris White
>
>
>
> --
> Command Prompt, Inc., home of PostgreSQL Replication, and plPHP.
> Postgresql support, programming shared hosting and dedicated hosting.
> +1-503-667-4564 - jd@commandprompt.com - http://www.commandprompt.com
> Mammoth PostgreSQL Replicator. Integrated Replication for PostgreSQL


--
Command Prompt, Inc., home of PostgreSQL Replication, and plPHP.
Postgresql support, programming shared hosting and dedicated hosting.
+1-503-667-4564 - jd@commandprompt.com - http://www.commandprompt.com
Mammoth PostgreSQL Replicator. Integrated Replication for PostgreSQL

Attachment

Re: Need help

From
"Scott Marlowe"
Date:
On Wed, 2004-10-20 at 12:57, Chris White (cjwhite) wrote:
> I am running 7.4.2 and I am seeing a strange error. I am using jdbc to
> update a table with the following statement:
>
> update vm_message set usecount=4 where messsage id='1234567';


Is that really your query, cut and pasted?  Is that space between
message and id supposed to be there?  Just wondering.


Re: Need help

From
"Chris White (cjwhite)"
Date:
It was a mistype, it was not a cut and paste, as I  do not have email on the
system that has access to the system running the DB. There is meant to be no
space in messageid

-----Original Message-----
From: Scott Marlowe [mailto:smarlowe@qwest.net]
Sent: Wednesday, October 20, 2004 2:53 PM
To: cjwhite@cisco.com
Cc: pgsql-admin@postgresql.org
Subject: Re: [ADMIN] Need help

On Wed, 2004-10-20 at 12:57, Chris White (cjwhite) wrote:
> I am running 7.4.2 and I am seeing a strange error. I am using jdbc to
> update a table with the following statement:
>
> update vm_message set usecount=4 where messsage id='1234567';


Is that really your query, cut and pasted?  Is that space between message
and id supposed to be there?  Just wondering.