I need to recreate the excel function "VLookup" in Access. I've seen the function Dlookup in Access and (1) I can't figure out how to use it exactly * (2) I don't think it will do what I need it to do anyway.
Here's the situation:
I want the user to input a date into a field on a form. Based on the date, I want Access to reference another table I have that has date ranges and the corresponding accounting month (based on our work calendar).
Reference table looks like this:
Begin End AcctMonth
1/1/06 1/29/06 2006Jan
1/30/06 2/26/06 2006Feb
2/27/06 3/26/06 2006Mar
So, when a user inputs 1/31/06, I want access to return a value of "2006Feb".
I am an intermediate VBA user, but I don't even know what DAO is and I have never used an SQL. I've searched this topic on the internet and seen some examples but I haven't been able to decode what the SQL statement was saying.
Please help!
Here's the situation:
I want the user to input a date into a field on a form. Based on the date, I want Access to reference another table I have that has date ranges and the corresponding accounting month (based on our work calendar).
Reference table looks like this:
Begin End AcctMonth
1/1/06 1/29/06 2006Jan
1/30/06 2/26/06 2006Feb
2/27/06 3/26/06 2006Mar
So, when a user inputs 1/31/06, I want access to return a value of "2006Feb".
I am an intermediate VBA user, but I don't even know what DAO is and I have never used an SQL. I've searched this topic on the internet and seen some examples but I haven't been able to decode what the SQL statement was saying.
Please help!