Deborah
On 31 Mar 2007, at 02:20, Tim Mansour wrote (in part):
... you could also use the technique where the relationship is
defined to include a sort order, Descending Sort by
Numeric_Accession_Number, in which case you can simply use:
Max_Accession = TO2::Numeric_Accession_Number
to get the first value found as defined by the relationship: in our
case this will return the highest Numeric_Accession_Number. This
negates the need for the Max ( ) function.
this got me thinking ... using a sorted relationship could be slow
for large a data set, but then so could using the Max () function.
So ...
skip the relationship method,
add a global calc field:
max_accession = if ((accession=filter(accession;"0123456789"))and
(accession > max_accession) ; accession ; max_accession)
making sure to UNCHECK "Do not replace existing value (if any)"
(optionally) set accession to auto_enter max_accession + 1 (allowing
user to modify during data entry)
having said all that, seems to me that unless you actually want to
display max_accession for some (other) reason, using a straight
serial auto-enter as Stan suggested is fine
cheers
Tom