Results 1 to 8 of 8
  1. #1
    jamo is offline Novice
    Windows XP Access 2010 32bit
    Join Date
    Oct 2012
    Posts
    20

    quarterly calculation

    I have this code in my query
    Code:
    Quarter: DatePart("q",[Date Paid])
    that quartely. My financial year is July to June how do I ammend this code to reflect my financial year so that my first quarter will be july?

  2. #2
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    Try:

    Quarter: DatePart("q",DateAdd("m",6,[Date Paid]))

  3. #3
    jamo is offline Novice
    Windows XP Access 2010 32bit
    Join Date
    Oct 2012
    Posts
    20
    Thanks it works but my headings still read jan, feb, march for the first quarter instead of july aug september

  4. #4
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,849
    How are you identifying your headings now?
    You have to adjust for the offset of fiscal year (6 months).

    Sounds like where you normally have quarter 1 (months 1,2,3) you have to add 6 (7,8,9) Fiscal qtr months.

  5. #5
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    Thanks it works but my headings still read jan, feb, march for the first quarter instead of july aug september
    Headings??? You didn't mention anything about headings.
    Are they the result of some formula? If so, what is the formula?

  6. #6
    jamo is offline Novice
    Windows XP Access 2010 32bit
    Join Date
    Oct 2012
    Posts
    20
    This is the code
    Code:
    MonthOfQuarter: (Month([Date Paid]) Mod 6)
    it gives the month of the quarter

  7. #7
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    MonthOfQuarter: (Month([Date Paid]) Mod 6)
    I really don't understand what you are trying to do with this. This will just return a number from 0-5.

    Regardless of which quarter you are in, if you are just trying to extract the month name from a date, you just need the MONTH function, and nothing else.
    What exactly are you trying to do?
    Maybe if you work us through a simple example, it will make more sense.

  8. #8
    jamo is offline Novice
    Windows XP Access 2010 32bit
    Join Date
    Oct 2012
    Posts
    20
    thanks fixed, just needed to be patient

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 08-10-2012, 02:11 PM
  2. Replies: 1
    Last Post: 06-22-2011, 07:55 PM
  3. quarterly, excludes weekends and holidays
    By madagaluna in forum Queries
    Replies: 2
    Last Post: 04-01-2011, 12:56 PM
  4. value calculation
    By kyle in forum Access
    Replies: 3
    Last Post: 03-06-2011, 12:29 PM
  5. Quarterly Amounts
    By Brian62 in forum Queries
    Replies: 9
    Last Post: 10-16-2009, 02:18 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums