Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

please need urgent reply

Hi..Can any one help me this issue....Actually i have a dimensions Fiscal year(2010,2011,2012,....) , Fiscal Quarter(Q1,Q2,Q3,Q4,...) ,Fiscal Month (Jan,Feb,March,...) but my case is by using any of those i need to show Fiscal Week like (W1,W2,W3,W4...)...Is it possible....

7 Replies
er_mohit
Master II
Master II

Try this

'W' & Ceil(Week(TempDate)/8) as Fiscalweek

TempDate is my date field

Not applicable
Author

where i have to give this condition...

er_mohit
Master II
Master II

in script level where your other fields you make like for fiscal year,and for month there you write this

and you will get fiscalweek fieldname when reload your data

you have to write this in your edit script  for short cut press ctrl+E

where you mentioned your date field there you put this code make sure you chanfe the date field

hope it helps

Not applicable
Author

hi ..i am nt getting exact result please find the below attachment , i am sending the dimdate qvd go through that once let me know how to get that exact result like FiscalWeek data should be like W1(for the 1st week),W2(for the second week),W3(for the 3rd week)......please

Regards,

X.

anandathome
Creator
Creator

Hi Shobha,

     Please attache the qvd.

-Anand.

Not applicable
Author

  Hi..this the script i have for the dim date

LOAD

Day,
CalendarWeek,
FiscalWeek,
Month,
CalendarQuarter,
FiscalQuarter,
CalendarYear,
FiscalYear
FROM

(
qvd

);

anandathome
Creator
Creator

I am assuming that you have one FullDate column in your calendar/date dimension.

Use the below LOAD script

LOAD

Day,

CalendarWeek,

FiscalWeek,

Month,

CalendarQuarter,

FiscalQuarter,

CalendarYear,

FiscalYear,

'W' & Week(Date(FullDate,'YYYY-MM-DD')) as WeekNo1,

'W' & If((Week(Date(FullDate,'YYYY-MM-DD')) - (Week(Date('2013-04-01'))-1))>0,(Week(Date(DOCDATE,'YYYY-MM-DD')) - (Week(Date('2013-04-01'))-1)),52+(Week(Date(DOCDATE,'YYYY-MM-DD')) - (Week(Date('2013-04-01'))-1))) as WeekNo2

FROM

(qvd

);

Note: WeekNo1 is when your calendar year and fiscal year are same.

WeekNo2 is when your fiscal year starts on 1st April.

Let me know in case of any issue.

-Anand