Armin Waibel said:
> Robert Crawford wrote:
>
>> Armin Waibel said:
>>
>>>Do you only use the PB-api? This bug is odmg-api related.
>>
>>
>> I only use the PB-api.
>>
>
> Then you shouldn't get problems with negative sequence numbers.
> Can you describe me with some pseudo code an test case to reproduce your
> problem?

>From memory, the code looks something like this:

PersistenceBroker broker =
PersistenceBrokerFactory.createPersistenceBroker(pbKey);
User user = new User();
user.setEmailAddress(emailAddress);
// more setters here, nothing that touches the primary key
broker.store(user);

At this point the database has a negative number for the primary key and,
from what I can recall from my debugging, the user object has zero in the
primary key field.

Here's the start of the class descriptor:

<class-descriptor
    class="com.kloognome.accesscontrol.ojb.UserInstance"
    table="ac_users">
    <field-descriptor name="userNbr" column="user_nbr" jdbc-type="INTEGER"
primarykey="true" autoincrement="true" access="readonly"/>



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to