Changeset 2034

Show
Ignore:
Timestamp:
05/04/10 18:10:50 (4 months ago)
Author:
x.pechoultres@…
Message:

Dbo : manage automatic transaction on dbCreate()

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/modules/Dbo/source/create.cl

    r1023 r2034  
    33[private/dbCreateSimple(db:Db/Database, self:object, updateIdMap?:boolean, dbSimpleProps:list[dbProperty]) : boolean 
    44 -> //[DBOJECTS] dbCreateSimple(self = ~S) // self, 
     5        if (db.Db/autoStartTransaction? & not(db.Db/onTransaction?)) Db/beginTransaction(db), 
    56        let idProp := getIdProperty(self), // just id 
    67                dbAutoIncrementProperties := getAutoIncrementProperties(self), // no id, just autoincrement 
     
    5152[private/dbCreateWithGenerator(db:Db/Database, self:object, dbProps:list[dbProperty]) : boolean 
    5253 -> //[DBOJECTS] dbCreateWithGenerator(self = ~S) // self, 
     54        if (db.Db/autoStartTransaction? & not(db.Db/onTransaction?)) Db/beginTransaction(db), 
    5355        let idProp := getIdProperty(self), // just id 
    5456                dbAutoIncrementProperties := getAutoIncrementProperties(self), // no id, just autoincrement