Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
paulyeo11
Master
Master

I have month and year but cannot get Quarter

Hi All,


Below script from fourm people here work fine :-


SubField([Opportunities Expected Close Date],'-' ,3) as Year,

Num(Month(Date#([Opportunities Expected Close Date], 'MM-DD-YYYY'))) as Month,

Below from me , not working :-

    

'Q' & ceil(Month(Date#([Opportunities Expected Close Date])),3)/3 as [quarter],


Can some one tell me where i go wrong ?


Paul

1 Solution

Accepted Solutions
pradosh_thakur
Master II
Master II


Year(Date#([Expected Close Date], 'MM-DD-YYYY')) as Year,

Month(Date#([Expected Close Date], 'MM-DD-YYYY')) as Month,

'Q' & ceil(Month(Date#([Expected Close Date], 'MM-DD-YYYY')) /3) as Quarter



Learning never stops.

View solution in original post

16 Replies
prma7799
Master III
Master III

 

    

'Q' & ceil(Month(Date#([Opportunities Expected Close Date])),3)/3 as [quarter],

Have you tried this

'Q' & Ceil(Month([Opportunities Expected Close Date]) / 3) AS Quarter,

paulyeo11
Master
Master
Author

Hi PM,

Thank you for your help.

No error msg , but does not display value.

Paul

prma7799
Master III
Master III

or you can try like this

     'Q' & ceil(Month(Date#([Opportunities Expected Close Date],'DD/MM/YYYY')),3)/3 as [NewQuarter],

prma7799
Master III
Master III

Take [Opportunities Expected Close Date] field as list box and share screen shot...

paulyeo11
Master
Master
Author

Hi PM

Still display nothing. How to convert date format DD-MM-YYYY into Year ? 2 days ago i have ask forum on how to compute the year from my date field on the above link. May be it is due to my date field is quite complicated.

Paul

prma7799
Master III
Master III

have you tried this??

'Q' & ceil(Month(Date#([Opportunities Expected Close Date],'DD/MM/YYYY')),3)/3 as [NewQuarter]


or change date format mention in bold above according to your date

paulyeo11
Master
Master
Author

PM

Still Can not.

Paul

prma7799
Master III
Master III

Please share screen shot like below

pos.png

pradosh_thakur
Master II
Master II


Year(Date#([Expected Close Date], 'MM-DD-YYYY')) as Year,

Month(Date#([Expected Close Date], 'MM-DD-YYYY')) as Month,

'Q' & ceil(Month(Date#([Expected Close Date], 'MM-DD-YYYY')) /3) as Quarter



Learning never stops.