P
PayeDoc
Hello All
I have a large-ish table [x confirmed] (~80,000 records, 25 fields) which
includes the fields 'employee' (text), 'mthnumber' (integer) and 'nicode'
(text). Most of the records with the same 'employee' value have the same
'nicode' value, but some 'employee' values have more than one corresponding
'nicode' value. I need a query that will return, for each value of
'employee' that has more than one corresponding 'nicode' value, the lowest
value of 'mthnumber' that is associated with the 'nicode' value that has the
highest 'mthnumber' value. To put this into English, 'mthnumber' represents
month numbers (where 1 = January 2008, 2 = February 2008, etc. etc. etc.),
and I need the month number in which the changed value of 'nicode' first
occurs, for each employee.
I'm sure this can be done, but I've been trying and failing to get it right
all day and now my brain hurts!!
Hope someone can help.
Many thanks
Leslie Isaacs
I have a large-ish table [x confirmed] (~80,000 records, 25 fields) which
includes the fields 'employee' (text), 'mthnumber' (integer) and 'nicode'
(text). Most of the records with the same 'employee' value have the same
'nicode' value, but some 'employee' values have more than one corresponding
'nicode' value. I need a query that will return, for each value of
'employee' that has more than one corresponding 'nicode' value, the lowest
value of 'mthnumber' that is associated with the 'nicode' value that has the
highest 'mthnumber' value. To put this into English, 'mthnumber' represents
month numbers (where 1 = January 2008, 2 = February 2008, etc. etc. etc.),
and I need the month number in which the changed value of 'nicode' first
occurs, for each employee.
I'm sure this can be done, but I've been trying and failing to get it right
all day and now my brain hurts!!
Hope someone can help.
Many thanks
Leslie Isaacs