Carl, 1) The pk field is a postgres serial type. I assume that there is code in dabo to fetch the new pk value via a nextval() pass-through function.
2) Because the design specs call for it. What problem do you see with this? Larry -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Carl Karsten Sent: Monday, April 16, 2007 11:22 AM To: Dabo Users list Subject: Re: [dabo-users] Can we retrieve the new pk in the app? [EMAIL PROTECTED] wrote: > We need to generate and save a field value with a unique number, part of > which we would like to be the actual pk of the record. For example... > > yynnnnn-xxx-xxx-xx > > where nnnnn is the pk id. What is generating the pk? (app or server) Why are you doing such a thing? (not to be confused with "don't do that", even if it is going though my mind.) > > I looked adding the code in the afterSave using the getPK, but getPK shows > the temp number. Is the new (real) pk available to me? (this Q directed to list) If the app generates the pk, does dabo still use temp PK's for new records? or, if the app is generating the key, does dabo call the get PK routine when a new record is created for editing, or when a new record is being saved? Carl K [excessive quoting removed by server] _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users Searchable Archives: http://leafe.com/archives/search/dabo-users This message: http://leafe.com/archives/byMID/dabo-users/!&[EMAIL PROTECTED]
