Sunday, May 29, 2005

[Opf3] What is the AutoNumber property in the FieldAttribute

The "AutoNumber" property in the FieldAttribute may be set to true to have Opf3 retrieved the next number for a primary key from the storage (database etc). This works only with databases that support sequences (like Oracle, PostgreSql, PervasiveSql) or autoincrement (like Access, MSSQL Server, VistaDB).

All storages that come with the framework support this feature. It's highly recommended that all storages that are released to the public support it.

AutoNumbers are supported only for one property of the persistent object! Opf3 does not throw an exception if you mark more then one property as "AutoNumber" but will only fill the first that is found.


Post a Comment

<< Home