Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

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

Count according monthname in load script

Hi all!     

I have a temp table like:

Date (yyyy-mm-dd), Value

2013-02-03, Red

2013-04-03, White

2013-04-04, White

2013-04-05, White

2014-02-08, White

2014-02-12, White

2014-01-10, White

2014-01-01, White

2014-01-02, White

2014-01-04, White

I need to make a resident load from this table into a new table grouped by MonthName and counting records, like this:

MonthName, Count of records

2013-02, 1

2013-04, 3

2014-01, 4

2014-02, 2

Does anyone know how to do it?

Thanx!!

Pablo

1 Solution

Accepted Solutions

Re: Re: Count according monthname in load script

QlikCommunity_Thread_140000_Pic1.JPG.jpg

QlikCommunity_Thread_140000_Pic2.JPG.jpg

hope this helps

regards

Marco

4 Replies

Re: Count according monthname in load script

tabInput:

LOAD * Inline [

Date, Value

2013-02-03, Red

2013-04-03, White

2013-04-04, White

2013-04-05, White

2014-02-08, White

2014-02-12, White

2014-01-10, White

2014-01-01, White

2014-01-02, White

2014-01-04, White

];

tabOutput:

LOAD Date(MonthName(Date),'YYYY-MM') as MonthName,

     Count(Date) as [Count of records]

Resident tabInput

Group By MonthName(Date);

Re: Re: Count according monthname in load script

QlikCommunity_Thread_140000_Pic1.JPG.jpg

QlikCommunity_Thread_140000_Pic2.JPG.jpg

hope this helps

regards

Marco

Not applicable

Re: Count according monthname in load script

Thanx Marco!

Re: Re: Count according monthname in load script

You're welcome

regards

Marco