Qlik Community

QlikView Deployment

Discussion Board for collaboration related to QlikView Deployment.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

Not applicable

Position

Hello,

I have pro year/ month the sales of specific cars e.g. opel, fiat, Mercedes etc.

Now i want to have a pivot table

with for the actual year the sells of cars and the position

the previous year the sells of cars and the position within that year

e.g.

             2014               2013

             sells position

fiat        1000 1            fiat 800 3

opel         800 2           Opel 900 1

Mercedes  700 3        Mercedes  850 2

you can see fiat 2014 position 1 2013 position 3

opel 2014 position 2 2013 position 1

Mercedes 2014 position 3 2013 position 2

How to realise this?

2 Replies

Re: Position

Hi,

one solution could be:

QlikCommunity_Thread_142228_Pic1.JPG.jpg

QlikCommunity_Thread_142228_Pic2.JPG.jpg

tabCarSales:

LOAD *,

    Month(MonthName) as Month,

    Ceil(Month(MonthName)/3) as Quarter,

    QuarterName(MonthName) as QuarterName,

    Year(MonthName) as Year;  

LOAD *,

    Ceil(Rand()*15000)as Sales,

    MonthName(AddMonths(MakeDate(2010),IterNo()-1)) as MonthName

Inline [

Car Manufacturer

Audi

BMW, Mini

Fiat

Ford

Mercedes-Benz

Opel

Porsche

Volkswagen

]

While AddMonths(MakeDate(2010),IterNo()-1) <= Today();

hope this helps

regards

Marco

jsakalis
New Contributor III

Re: Position

Hi Ama,

Please see attached app.

Community Browser