C
Candice
Hi, I have inherited some Access databases that are using 'LastOf' in queries
to pull records to show on forms and reports. I have never used this function
but apparently it returns the 'last' record of the recordset. This doesn't
really mean anything to me because there is no Order By clause. I assume
Access is ordering the records in whatever way it chooses (the order they
were created?) and giving me the last one. So my question: Shouldn't LastOf
always be used with OrderBy? The users are telling me they have intermittent
problems with a boolean field showing up true one day, and false the next on
reports and forms. I think this is due to using LastOf with no OrderBy. Do
you think I'm right?
To make matters worse, I can see that when users update various columns on
the table through a form, the form adds a new row to the table instead of
updating the current row. So now data on all previous rows is hidden by the
most current row. I believe the programmer must have been trying to use
'LastOf' to overcome this problem. But it is unsuccesful. This stinks!
Suggestions?
to pull records to show on forms and reports. I have never used this function
but apparently it returns the 'last' record of the recordset. This doesn't
really mean anything to me because there is no Order By clause. I assume
Access is ordering the records in whatever way it chooses (the order they
were created?) and giving me the last one. So my question: Shouldn't LastOf
always be used with OrderBy? The users are telling me they have intermittent
problems with a boolean field showing up true one day, and false the next on
reports and forms. I think this is due to using LastOf with no OrderBy. Do
you think I'm right?
To make matters worse, I can see that when users update various columns on
the table through a form, the form adds a new row to the table instead of
updating the current row. So now data on all previous rows is hidden by the
most current row. I believe the programmer must have been trying to use
'LastOf' to overcome this problem. But it is unsuccesful. This stinks!
Suggestions?