Returns a member list from the start of the quarter to the specified date member.
- Returned Output: List
- Library: PQL \ Semantic \ Date-Time
- Version: 2020.10.000
- Compatibility: Pyramid Query Language (PQL) data sources
* Click on the function's arguments above for more details on the input values.
- The member needs to be an existing member from either:
- a date-time flagged attribute in the model.
- a regular, multilevel hierarchy where there is a level of type "quarter"
- For details on how to employ and use this function see the semantic calculation overview.
Attribute vs Regular Hierarchy Formulations
When this function is used on a flat attribute / column of type "date-time", the function builds a set of members starting from the start of the quarter specified. In effect, the dates in the attribute drive the logic based on their actual date-time values.
When the function is used on a regular hierarchy (with multiple levels), the function returns all the elements in the same level starting with the first one found under the same parent item in the QUARTER level all the way up to itself. In effect, the logic ignores the date-time value of the elements and instead resolves the calculation based on the hierarchy and the parent item found specifically in the quarter level. If there is no quarter level, this function will not work.
Different Function types
- This regular hierarchical formulation is similar to the MDX "QTD" function.
- This attribute formulation is similar the full quarter function, but it calculates the range of dates from the start of the quarter to the specified date.
The QTD function using a date of 2016-02-05 produces a list of dates starting Jan 1 2016 -Feb 5 2016 when applied to the flat hierarchy called "dateKey".
Qtd( [data].[dateKey]. )
The QTD function using a member May 2008 produces a list of months starting with the first child of "Q2-2008" through to this member, since Q2 is marked as a member in the quarter level in the regular hierarchy called "Date".