Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear Qlikview user
I am using the WeekDay function and as expected it returns values from Mon, Tue, Wed, Thur, Fri, Sat, Sun
I would like to trim down the WeekDay function so it just returns the first letter of each day I.e. M, T, W, T, F, S, S
Does anyone know how this can be achieved?
Kind Regards
Helen
Even the second method?
Dual(Left(WeekDay(Date), 1), Num(WeekDay(Date))) as [1stLetterWeekDay]
May be like this:
Left(WeekDay(Date), 1) as [1stLetterWeekDay]
or
Dual(Left(WeekDay(Date), 1), Num(WeekDay(Date))) as [1stLetterWeekDay]
Try modifying the MAIN script tab
SET DayNames='Mon;Tue;Wed;Thu;Fri;Sat;Sun';
to below::
SET DayNames='M;T;W;T;F;S;S';
Hello Sunny
Thank you for your response
I have tried your techniques and unfortunately they are grouping the letters which are the same together I.e. Tue and Thu and both come under T now
Is there any way to stop the aggregation?
Kind Regards
Helen
Its the Qlikview nature to group the similar data if you have T and T how you will different it as Tue and Thu (don't consider the week order) .
Even the second method?
Dual(Left(WeekDay(Date), 1), Num(WeekDay(Date))) as [1stLetterWeekDay]
Your right Sunny
My mistake! The second option does work
Thank you so much!
Thanks
Helen
Although, I think you should also look into jpenuliar's solution. I think its sleeker than what I provided