Hi,
I am trying to create a query that does not return any records with the same BoxNo (box number) if those records also have a scheduled destruction year that is <=Year(Now())
I’ve spent almost 16 hours trying so many different IIf statements and expressions that I’m so confused. So, I hope if I show you an example of the records I need to filter and another example of the results I need that you can start me in the right direction. I would so grateful for your help
Example of boxed record fields and data:
BoxNo | Function | SchedDestruc | Year[SchedDestruc]
(text box)
003-81 | Daily Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/14 | 2014
003-82 | Daily Deposit | 12/31/16 | 2016
003-82 | Mo.Deposit | 12/31/16 | 2016
003-83 | Daily Deposit | 12/31/16 | 2016
003-83 | Mo. Deposit | 12/31/17 | 2017
003-83 | Daily Deposit | 12/31/14 | 2014
Example of what I need:
BoxNo | Function | SchedDestruc | Year[SchedDestruc]
003-81 | Daily Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/14 | 2014
003-82 | Daily Deposit | 12/31/16 | 2016
003-82 | Mo.Deposit | 12/31/16 | 2016
I am trying to create a query that does not return any records with the same BoxNo (box number) if those records also have a scheduled destruction year that is <=Year(Now())
I’ve spent almost 16 hours trying so many different IIf statements and expressions that I’m so confused. So, I hope if I show you an example of the records I need to filter and another example of the results I need that you can start me in the right direction. I would so grateful for your help
Example of boxed record fields and data:
BoxNo | Function | SchedDestruc | Year[SchedDestruc]
(text box)
003-81 | Daily Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/14 | 2014
003-82 | Daily Deposit | 12/31/16 | 2016
003-82 | Mo.Deposit | 12/31/16 | 2016
003-83 | Daily Deposit | 12/31/16 | 2016
003-83 | Mo. Deposit | 12/31/17 | 2017
003-83 | Daily Deposit | 12/31/14 | 2014
Example of what I need:
BoxNo | Function | SchedDestruc | Year[SchedDestruc]
003-81 | Daily Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/15 | 2015
003-81 | Mo. Deposit | 12/31/14 | 2014
003-82 | Daily Deposit | 12/31/16 | 2016
003-82 | Mo.Deposit | 12/31/16 | 2016