Skip to main content
Announcements
Customer Spotlight: Discover what’s possible with embedded analytics Oct. 16 at 10:00 AM ET: REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
brf10043
Creator
Creator

Quarter Refernce Lines

I'm working on a Grid chart with the X dimension being a "Implementation Date".  The Implementation Date can be any date in 2017.  Is there a way to write an expression that draws reference lines to at the start or end of each quarter? 

1 Solution

Accepted Solutions
sunny_talwar

Something like this?

Capture.PNG

View solution in original post

15 Replies
vishsaggi
Champion III
Champion III

Can you share a sample output you are looking for? Any sample data to look into please let us know?

brf10043
Creator
Creator
Author

Sure,  Here's my current chart.  I'd like to add vertical lines to indicate the transition from one quarter to another.  Once of the challenges is that I can't predict what the Implementation dates are going to be so I need the expression to look at the Implementation dates and determine where the lines should be.

vishsaggi
Champion III
Champion III

Do you have a calendar script used in this? Can you share some sample data here?

Create a field like this may be, i have not tried.

'Q' & Ceil(Month(Max(Date(Date#(S_ImprovementImpDate, 'DD-MMM-YYYY'), 'DD/MM/YYYY')))/3)  AS MaxQuarter

vishsaggi
Champion III
Champion III

Also check from Help:

QuarterEnd(date [, shift = 0 [, first_month_of_year = 1]])

Returns a value corresponding to a timestamp with the last millisecond of the quarter containing date. The default output format will be the DateFormat set in the script. Shift is an integer, where the value 0 indicates the quarter which contains date. Negative values in shift indicate preceding quarters and positive values indicate succeeding quarters. If you want to work with (fiscal) years not starting in January, indicate a value between 2 and 12 in first_month_of_year.

Examples:

quarterend ( '2005-10-29' ) returns '2005-12-31' with an underlying numeric value corresponding to '2005-12-31 23:59:59.999'

quarterend( '2005-10-29', -1 ) returns '2005-09-30' with an underlying numeric value corresponding to '2005-09-30 23:59:59.999'

quarterend ( '2005-10-29', 0, 3 ) returns '2005-11-30' with an underlying numeric value corresponding to '2005-11-30 23:59:59.999'

brf10043
Creator
Creator
Author

I am creating a Quarter value in my load to build a calendar but I can't seem to build reference lines on my Grid chart using it.  FYI - S_Implementation  date is linked to Comm_Date

  'Q' & ceil(month(Comm_Date) / 3) AS Quarter,

vishsaggi
Champion III
Champion III

Is it possible, can you share your app to look into?

brf10043
Creator
Creator
Author

Here is a stripped down version.  The load script is in tact.

vishsaggi
Champion III
Champion III

I am getting access denied for this QV document.

brf10043
Creator
Creator
Author

Apologies.  Try this version