If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
DLookup Function
In one table I have a transaction date, in a second table I have the closing
dates for the accounting periods. In the same table as the closing dates I have the fiscal month and fiscal year that represent the closing date. In a query I would like to pull in the fiscal month and fiscal year based on teh transaction date. |
#2
|
|||
|
|||
DLookup Function
So I want to look up the first period that has a closing date greater than
the transaction date. "QC Coug" wrote: In one table I have a transaction date, in a second table I have the closing dates for the accounting periods. In the same table as the closing dates I have the fiscal month and fiscal year that represent the closing date. In a query I would like to pull in the fiscal month and fiscal year based on teh transaction date. |
#3
|
|||
|
|||
DLookup Function
Here is my current formula.
DLookUp("[Fiscal Month]","ACCTG_PERIODS","[dbo_SOP10200]![ReqShipDate]=[ACCTG_PERIODS]![Closing Date]") Fiscal Month = field name withing the ACCTG_PERIODS table [dbo_SOP10200]![ReqShipDate] = table and field name of the transaction date [ACCTG_PERIODS]![Closing Date] = table and field name of the closing date "QC Coug" wrote: So I want to look up the first period that has a closing date greater than the transaction date. "QC Coug" wrote: In one table I have a transaction date, in a second table I have the closing dates for the accounting periods. In the same table as the closing dates I have the fiscal month and fiscal year that represent the closing date. In a query I would like to pull in the fiscal month and fiscal year based on teh transaction date. |
#4
|
|||
|
|||
DLookup Function
=DMin("[FiscalMonth]", "SecondTable", "[ClosingDate] #" & TransActionDate &
"#" I think the DMin function will work better for this. Since I don't know where you will have the Transaction Date, I dummied it up for the example. Just replace it with the reference to where you have the Transaction Date. "QC Coug" wrote: So I want to look up the first period that has a closing date greater than the transaction date. "QC Coug" wrote: In one table I have a transaction date, in a second table I have the closing dates for the accounting periods. In the same table as the closing dates I have the fiscal month and fiscal year that represent the closing date. In a query I would like to pull in the fiscal month and fiscal year based on teh transaction date. |
Thread Tools | |
Display Modes | |
|
|