Solved

Calculate Fiscal Year 7/1-6/30

Posted on 2009-03-30
4
783 Views
Last Modified: 2013-11-28
I could use assistance with a date serial expression (to be used in an MS Access query) that will calculate a fiscal year 7/1 - 6/30.
0
Comment
Question by:jaguar5554
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 24024617
0
 

Author Comment

by:jaguar5554
ID: 24024978
Thank you for the link; however,  I reviewed the MS solution prior to submitting my question on EE's site. I'm looking for an expression that will calculate the fiscal year starting with July 1. I believe the MS site's expression calculates the fiscal year starting with July 15. Perhaps I missed something... Any assistance would be greatly appreciated. Thank you!
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 24024988
did you see this part

Option Explicit
Const FMonthStart = 6   ' Numeric value representing the first month
                        ' of the fiscal year.
Const FDayStart = 16    ' Numeric value representing the first day of
                        ' the fiscal year.
Const FYearOffset = -1  ' 0 means the fiscal year starts in the
                        ' current calendar year.
                        ' -1 means the fiscal year starts in the
                        ' previous calendar year.
0
 
LVL 11

Expert Comment

by:mildurait
ID: 24025025
Something like this may return what you want
Note: Dates in 08/09 range would return 2009

Usage in Access Query
SELECT * FROM TABLE where FY(DATECOLUMN)=2009


Public Function FY(ByVal InputDate As Date) As Integer
 
    Dim y As Integer
    y = Year(InputDate)
    If Month(InputDate) >= 7 Then y = y + 1
    FY = y
 
End Function

Open in new window

0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question