You could assign an on insert trigger on the table. The logic in the trigger could guarantee each row has a value that makes it unique based on random numbers.
Ken On Mon 06/04/12, at 1:03, Michael J. Sinclair <[email protected]> wrote: Hi Bill, I don't think GUID is available in Rbase 9.5 (32), only Rbase 9.5 (64). I can live with the Random number generator picking numbers between 0 and 999999999. What I really need help with is how to make the EEP work with all rows including the last row. I think what I am looking for is something like ON EXIT ROW EEP, but I don't think that is an option anymore. Which EEP (Scrolling Region EEP vs DBedit field EEP) would be the correct place to put the EEP? Mike--- On Mon, 6/4/12, Bill Downall wrote: From: Bill Downall Subject: [RBASE-L] - Re: How to assign unique values to a column within a formTo: "RBASE-L Mailing List" Date: Monday, June 4, 2012, 11:33 AM Mike, If you are using 9.5, you should use GUID for this. See the 9.5 help. Bill On Mon, Jun 4, 2012 at 11:25 AM, Michael J. Sinclair <[email protected]> wrote: Hi All, In Rbase 9.5 32, I have a form with a scrolling region. I would like to assign a unique value to column such that each new row has a unique random value. For other columns, I would like to have all the new rows have the same value such as today's date. I know I can do this easily in the add variable / expression builder area, but somebody said that is not a great way to do it because it can slow down the form since each expression is recalculated evertime a field is exited. When I try to add rows, I tried using an ON EXIT EEP from a field to update the column with a unique flag, like this.... SET VAR vrand = (RANDOM(999999999)) UPDATE tablename SET column name = .vrand WHERE uniqueflag IS NULL (I know I have 1 chance in 999999999 that the value won't be unique, I can live with that) That seems to work for every row except the last row I add. The last row does not get any value. What is the right way to give each new row a unique column value within a scrolling region? I think my problem might that I am choosing the wrong type off EEP. Is there an ON EXIT ROW EEP? Mike

