Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

maasool
New Contributor III

Group Date to Month-Year without duplicates

Hello dear Qlik Community,

I have dates, which I would like to convert and group on month-year basis, so I could use it as a filter in QS app.

When I do conversion Date(POSTING_DATE,'MM-YYYY') then as a result, I get duplicate results. For example,
for each date, which is in January 2019, I get '01-2019'. However, I would like to have only one '01-2019' per
all the dates, which are in January 2019. How to achieve this?

Thanks
maasool

1 Solution

Accepted Solutions
Partner
Partner

Re: Group Date to Month-Year without duplicates

another solution is

date(monthstart(POSTING_DATE),'MM-YYYY') 

Your solution is showing only month and year but datas are stored with day also.

Regards

4 Replies

Re: Group Date to Month-Year without duplicates

Perhaps this

Date(Floor(POSTING_DATE),'MM-YYYY')

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Partner
Partner

Re: Group Date to Month-Year without duplicates

another solution is

date(monthstart(POSTING_DATE),'MM-YYYY') 

Your solution is showing only month and year but datas are stored with day also.

Regards

saar_lorena
New Contributor III

Re: Group Date to Month-Year without duplicates

If your data is duplicating, the issue is not with the period...

Can you upload your file here?

 

Thanks 😃

maasool
New Contributor III

Re: Group Date to Month-Year without duplicates

Thanks for thinking along everyone! Martinpohl solution did the work for me.