Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

techvarun
Valued Contributor II

YTD Analysis

Hi,

        I have data for two years and i want to display the result in a particular format. I have all the formulas and values are ready with me and needs the help from you to display the data in the format as per requirement.

attached the file which I have and the format which I need to show the output.

Attached is the Screenshots of the Input and output values

Thanks in Advance

Tags (2)
1 Solution

Accepted Solutions

Re: YTD Analysis

See attached qvw.


talk is cheap, supply exceeds demand
6 Replies

Re: YTD Analysis

Can you attach sample file?

techvarun
Valued Contributor II

Re: YTD Analysis

Hi Celamb,

     Thanks for ur quick reply.

      Updated the question with input excel.

Regards

jpapador
Valued Contributor

Re: YTD Analysis

You can create a Year to Date field in your calendar that will flag dates in previous years up to today.  It would look something like this in your script:

  If(InYearToDate(Date, $(vTodaysDate), 0)

                or InYearToDate(Date, $(vTodaysDate), -1)

                or InYearToDate(Date, $(vTodaysDate), -2)

                or InYearToDate(Date, $(vTodaysDate), -3)

                or InYearToDate(Date, $(vTodaysDate), -4)

                , 'YTD') as YTD,

Re: YTD Analysis

See attached qvw.


talk is cheap, supply exceeds demand
techvarun
Valued Contributor II

Re: YTD Analysis

Am using QlikView P E

Re: YTD Analysis

This is the script:

CrossTable(Year,Amount,2)

LOAD subfield(Year,'_',1) as KPI, SubField(Year,'_',-1) as Period,

     [2013],

     [2012]

FROM Input_YTD.xls (biff, embedded labels, table is [Sheet1$]);

And the pivot table looks like this:

comm90286.png

You can see the only expression of the pivot table in the caption. The dimensions Period and Year have been dragged to above the expression so they show horizontally.


talk is cheap, supply exceeds demand
Community Browser