DCount syntax prob. It will be an easy one if you know how.
Hi
I want to put an expression in a query that generates a field with sequential numbers. (1,2,3,4, etc.)
I have created an expression using DCount which works just fine.
The expression is this:
Num: DCount("*","ABC Query","ID <=" & [ID])
My problem is, however that I want to generate the sequence on a date field rather than ID. so following logic I have created this expression:
Num: DCount("*","ABC Query","Date <=" & [Date])
But this generates errors, I think due to the fact that the same date appears numerous times in my data. So I need to put in an expression that uses two fields date and time. Can anyone help me put this right?
Thanks in advance. And thanks to all of you who take the time to help newbies like me. Your help is invaluable.
BeesBoy
Hi
I want to put an expression in a query that generates a field with sequential numbers. (1,2,3,4, etc.)
I have created an expression using DCount which works just fine.
The expression is this:
Num: DCount("*","ABC Query","ID <=" & [ID])
My problem is, however that I want to generate the sequence on a date field rather than ID. so following logic I have created this expression:
Num: DCount("*","ABC Query","Date <=" & [Date])
But this generates errors, I think due to the fact that the same date appears numerous times in my data. So I need to put in an expression that uses two fields date and time. Can anyone help me put this right?
Thanks in advance. And thanks to all of you who take the time to help newbies like me. Your help is invaluable.
BeesBoy
Last edited: