G
Guest
Hi,
How can I add a field in my query that produces a sequencial number that
resets for every group of data (grouped in ascending order). For example, my
table contains:
ID Dte IN OUT *New Field*
1000 2/1/05 10:00 11:00 1
1000 2/1/05 12:00 14:00 2
1000 2/1/05 15:00 18:00 3
1000 2/2/05 12:00 15:00 1
1000 2/2/05 16:00 18:00 2
1000 2/3/05 11:00 15:00 1
The *new field* should be assigned based on ascending order of (ID, DTE and
IN fields).
My goal is to make a crosstab query out of this and put it in a report that
will look like this:
"ID"
Date 1st Shift 2nd Shift 3rd Shift
2/1/05 10:00 - 11:00 12:00 - 14:00 15:00 - 18:00
2/2/05 12:00 - 15:00 16:00 - 18:00
2/3/05 11:00 - 15:00
Thanks a lot.
How can I add a field in my query that produces a sequencial number that
resets for every group of data (grouped in ascending order). For example, my
table contains:
ID Dte IN OUT *New Field*
1000 2/1/05 10:00 11:00 1
1000 2/1/05 12:00 14:00 2
1000 2/1/05 15:00 18:00 3
1000 2/2/05 12:00 15:00 1
1000 2/2/05 16:00 18:00 2
1000 2/3/05 11:00 15:00 1
The *new field* should be assigned based on ascending order of (ID, DTE and
IN fields).
My goal is to make a crosstab query out of this and put it in a report that
will look like this:
"ID"
Date 1st Shift 2nd Shift 3rd Shift
2/1/05 10:00 - 11:00 12:00 - 14:00 15:00 - 18:00
2/2/05 12:00 - 15:00 16:00 - 18:00
2/3/05 11:00 - 15:00
Thanks a lot.