Re: Validation step?

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Tue Mar 30 2004 - 12:27:21 EST

  • Next message: Bill Fan: "Why "SELECT DISTINCT ..." is generated?"

    I agree, validation step should be added to the docs, as step #2. I
    will do that.

    Andrus

    On Mar 30, 2004, at 10:58 AM, Gentry, Michael wrote:

    > I think there needs to be an addition made to this part of the
    > documentation (1.1M4):
    >
    > ============
    >
    > 6.3.3 Committing All Modified DataObjects
    >
    > All of the objects with changes (what "changes" mean is discussed
    > above)
    > are committed to the database with a single method call on the
    > DataContext:
    >
    > * public void commitChanges()
    >
    > Method commitChanges takes care of building correct SQL statements,
    > generating primary keys and transactional behaviour. It roughly follows
    > this scenario:
    >
    > * Checks if there are any changed objects.
    > * Checks if there are any NEW objects.
    > * Generates primary keys for any NEW objects that require
    > autogenerated key.
    > * Builds any needed SELECT, UPDATE, DELETE queries.
    > * Starts the database transaction.
    > * Runs the queries.
    > * Commits transaction.
    > * Changes all committed objects state to
    > PersistenceState.COMMITTED.
    > * Updates internally stored snapshots of the recently saved
    > objects.
    >
    > ============
    >
    > When is the validation (validateFor*) done? My assumption would be
    > step
    > #2 and if an exception is thrown, don't continue.
    >
    > Thanks,
    >
    > /dev/mrg
    >
    >



    This archive was generated by hypermail 2.0.0 : Tue Mar 30 2004 - 12:27:25 EST