Field values based on previous records

Joined
Feb 8, 2007
Messages
1
Reaction score
0
I need a query that can update a field to a value that depends on the previous record value (a "running counter"). For example:

If field PRODUCT = PRODUCT(previous record), then COUNT = COUNT(previous record) + 1 else COUNT = 1.

I wrote a VBA procedure that does the trick, but every 10000 records or so the program blocks due to a "file-lock count exceded", or something like that.

I am new to this forum, and was not able to find a previous post in this regard.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top