A
AccessIM
Is it possible to compare a field in a record to a different field in the
previous record?
For example, I would like to create a field that compares the RcvdDate field
in record 2 to the LeadTimeEndDate in record 1, the RcvdDate field in record
3 to the LeadTimeEndDate in record 2 and so on. If the received date is
before the previous record’s LeadTimeEndDate, I would like it to say
“Received Within Previous Receiving’s Lead Timeâ€. If not, it should say “Not
Received Within Previous Receiving’s Lead Timeâ€.
Below is a sample of the data. LeadTimeEndDate is a calculated field that
add the number of days in the Vendor_Lead_Time field to the RcvdDate. The
Type field would be the field I want to show the results of the comparison.
Item Code Description PO# RcvdDate Vendor_Lead_Time LeadTime EndDate Type
8856813 DEEP MSTR BDY LTN 420842 5/27/2009 7 6/3/2009
8856813 DEEP MSTR BDY LTN 422875 6/4/2009 7 6/11/2009 Not
Received Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 423943 6/10/2009 7 6/17/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 423947 6/16/2009 7 6/23/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 424934 6/22/2009 7 6/29/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 426064 6/29/2009 7 7/6/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 426066 7/1/2009 7 7/8/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 427135 7/2/2009 7 7/9/2009 Received
Within Previous Receiving’s Lead Time
Thank you in advance.
previous record?
For example, I would like to create a field that compares the RcvdDate field
in record 2 to the LeadTimeEndDate in record 1, the RcvdDate field in record
3 to the LeadTimeEndDate in record 2 and so on. If the received date is
before the previous record’s LeadTimeEndDate, I would like it to say
“Received Within Previous Receiving’s Lead Timeâ€. If not, it should say “Not
Received Within Previous Receiving’s Lead Timeâ€.
Below is a sample of the data. LeadTimeEndDate is a calculated field that
add the number of days in the Vendor_Lead_Time field to the RcvdDate. The
Type field would be the field I want to show the results of the comparison.
Item Code Description PO# RcvdDate Vendor_Lead_Time LeadTime EndDate Type
8856813 DEEP MSTR BDY LTN 420842 5/27/2009 7 6/3/2009
8856813 DEEP MSTR BDY LTN 422875 6/4/2009 7 6/11/2009 Not
Received Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 423943 6/10/2009 7 6/17/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 423947 6/16/2009 7 6/23/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 424934 6/22/2009 7 6/29/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 426064 6/29/2009 7 7/6/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 426066 7/1/2009 7 7/8/2009 Received
Within Previous Receiving’s Lead Time
8856813 DEEP MSTR BDY LTN 427135 7/2/2009 7 7/9/2009 Received
Within Previous Receiving’s Lead Time
Thank you in advance.