Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi ,
I have a report to plot tracking Half Monthly Counts and Premiums for which i use a master calendar all i need is a field
which indicates if a given date ie 01/03/2014 falls in 1st half of the month or 2nd half . I know i can do a >15 or <15 if else condition to achieve it but i was wondering is we could use any Date Functions of Qlikview Script to build it ?
Status | Feb - 1st Half | Feb - 2nd Half | Mar - 1st Half | Mar - 2nd Half | Apr - 1st Half | Apr - 2nd Half | May - 1st Half | Total | ||||||||
Count | Prem. | Count | Prem. | Count | Prem. | Count | Prem. | Count | Prem. | Count | Prem. | Count | Prem. | Count | Prem. | |
Pending | ||||||||||||||||
Accepted | ||||||||||||||||
Cancelled | ||||||||||||||||
Rejected |
No, I don't know a specialized date function for that purpose. But as you said, creating a flag in your master calendar should be easy, like
LOAD *,
Month & ' - ' & Half as MonthHalf;
LOAD
Date,
Month(Date) as Month,
if(Day(Date) < 15, dual('1st Half',1), dual('2nd Half',2) ) as Half,
...
FROM ...;
or adapt the condition to how you want to distinguish your halfs.