Re: To Dep PK bug?

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Mon Nov 08 2010 - 00:21:46 UTC

  • Next message: Marek Šab: "Composite entity model"

    Very odd. Please file a Jira. Maybe we can reproduce it with our unit tests? So what is optimistically locked in this case?

    Andrus

    On Nov 5, 2010, at 9:30 AM, Michael Gentry wrote:

    > It even fails if I include the dependent:
    >
    >
    > DataContext dataContext = DataContext.createDataContext();
    >
    > User admin = dataContext.newObject(User.class);
    >
    > admin.setName("Administrator");
    > admin.setUsername("admin");
    >
    > Avatar avatar = dataContext.newObject(Avatar.class);
    > admin.setAvatar(avatar);
    >
    > dataContext.commitChanges();
    >
    > admin.setName("The Administrator");
    >
    > dataContext.commitChanges();
    >
    >
    > Same issue. Both records get inserted this time (ID = 200). Then on
    > the second commit the ID goes to null in the master (User) record.
    >
    > mrg
    >



    This archive was generated by hypermail 2.0.0 : Mon Nov 08 2010 - 00:22:14 UTC