You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-dev@db.apache.org by "Robert S. Sfeir" <ro...@codepuccino.com> on 2004/06/22 02:11:03 UTC

More Postgresql errors

This is a new one I just noticed, among the 2 others:

SQL failure while insert object data for class
org.apache.ojb.broker.Article, PK of the given object is [ articleId=88940],
object was ---- Article No: 88940 Description: repeated Article
ProductGroupId: 1 ProductGroupName: null stock: 0 price: 0.0 stock-value 0.0
, exception message is [ERROR: duplicate key violates unique constraint
"artikel_pkey" ]

org.apache.ojb.broker.PersistenceBrokerSQLException: SQL failure while
insert object data for class org.apache.ojb.broker.Article, PK of the given
object is [ articleId=88940], object was ----Article No: 88940Description:
repeated ArticleProductGroupId: 1ProductGroupName: nullstock: 0price:
0.0stock-value 0.0, exception message is [ERROR: duplicate key violates
unique constraint "artikel_pkey"] at
org.apache.ojb.broker.accesslayer.JdbcAccessImpl.executeInsert(JdbcAccessImp
l.java:243) at 
org.apache.ojb.broker.core.PersistenceBrokerImpl.storeToDb(PersistenceBroker
Impl.java:1658) at 
org.apache.ojb.broker.core.PersistenceBrokerImpl.store(PersistenceBrokerImpl
.java:1575) at 
org.apache.ojb.broker.core.PersistenceBrokerImpl.store(PersistenceBrokerImpl
.java:1526) at 
org.apache.ojb.broker.core.DelegatingPersistenceBroker.store(DelegatingPersi
stenceBroker.java:180) at
org.apache.ojb.broker.core.DelegatingPersistenceBroker.store(DelegatingPersi
stenceBroker.java:180) at
org.apache.ojb.broker.KeyConstraintViolationTest.testKeyViolation(KeyConstra
intViolationTest.java:50) at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
) at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)Caused by: org.postgresql.util.PSQLException: ERROR: duplicate key
violates unique constraint "artikel_pkey" at
org.postgresql.util.PSQLException.parseServerError(PSQLException.java:139)
at org.postgresql.core.QueryExecutor.executeV3(QueryExecutor.java:152) at
org.postgresql.core.QueryExecutor.execute(QueryExecutor.java:100) at
org.postgresql.core.QueryExecutor.execute(QueryExecutor.java:43) at
org.postgresql.jdbc1.AbstractJdbc1Statement.execute(AbstractJdbc1Statement.j
ava:517) at 
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.j
ava:50) at 
org.postgresql.jdbc1.AbstractJdbc1Statement.executeUpdate(AbstractJdbc1State
ment.java:273) at 
org.apache.ojb.broker.accesslayer.JdbcAccessImpl.executeInsert(JdbcAccessImp
l.java:198) ... 22 more



---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Re: More Postgresql errors

Posted by Martin Kalén <ma...@curalia.se>.
Robert S. Sfeir wrote:

> This is a new one I just noticed, among the 2 others:
[...snip...]
> .java:25)Caused by: org.postgresql.util.PSQLException: ERROR: duplicate key
> violates unique constraint "artikel_pkey" at
[...snip...]
> org.apache.ojb.broker.KeyConstraintViolationTest.testKeyViolation
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^

This is how it should be. I was also a bit confused about all the stack-
traces in the output files, before finding that the quickest way to spot
what's wrong is to go down to the lines like:

Testcase: testX took Y,Z sec

And then look for "caused ERROR".

Regards,
  Martin

-- 
Martin Kalén
Curalia AB              Web:  http://www.curalia.se
Orrspelsvägen 2B        Mail: info@curalia.se
SE-182 79  Stocksund    Tel:  +46-8-410 064 40

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org