Last day of current quarter

  • Hello

    I'd like some of my SSRS reports to default to show the dates of the current financial quarter when they run.

    I'm in the UK so Q1 = 1/4/18 - 30/6/18   etc

    I have two date parameters. For the first parameter I've used this expression:

    =DateAdd(DateInterval.Quarter, DateDiff(DateInterval.Quarter, CDate("1/1/1900"), Today()), CDate("1/1/1900"))

    which when I run the report defaults to 1/4/18, which is what I want.

    However I've been unable to work out an expression to bring through the final day of the current quarter.

    Any ideas of how to achieve this would be appreciated.

    Thanks.

  • faulknerwilliam2 - Wednesday, June 20, 2018 3:35 AM

    Hello

    I'd like some of my SSRS reports to default to show the dates of the current financial quarter when they run.

    I'm in the UK so Q1 = 1/4/18 - 30/6/18   etc

    I have two date parameters. For the first parameter I've used this expression:

    =DateAdd(DateInterval.Quarter, DateDiff(DateInterval.Quarter, CDate("1/1/1900"), Today()), CDate("1/1/1900"))

    which when I run the report defaults to 1/4/18, which is what I want.

    However I've been unable to work out an expression to bring through the final day of the current quarter.

    Any ideas of how to achieve this would be appreciated.

    Thanks.

    Quick suggestion, add one quarter and then subtract one day.
    😎

  • Thanks, will give that a whirl. Thanks for the quick response.

    I think I've managed to resolve this slightly differently via:

    =DateAdd(DateInterval.Quarter, DateDiff(DateInterval.Quarter, CDate("1/1/1900"), Today()) + 1, CDate("31/12/1899"))

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply