Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
nareshthavidishetty
Creator III
Creator III

Dynamic Objects on Year and Month

Hi all,

I want to create dynamic calendar,

I have the data like,

DATE(DD/MM/YYYY)

19/04/2007

17/05/2007

31/05/2007

14/06/2007

16/06/2007

17/06/2007

02/07/2007

05/07/2007

I want to create Dynamic calendar  on (MM/YYYY) basis.

When I'm trying to do (MM/YYYY) format, it is not working.

PFA of QVW,

Can you please any one help on these...

11 Replies
chaper
Creator III
Creator III

Why are you using date# in script??? Use Date(Orders,'MM/YYYY')

nareshthavidishetty
Creator III
Creator III
Author

In my case the data is like('DD/MM/YYYY hh:mm:ss'),

if i am doing  Date(Orders,'MM/YYYY')  it allowing duplicates.

ex:

19/04/2007 00:00:00

19/04/2007 12:03:59,

because of that i am using date# function:date#(Date(Orders,'MM/YYYY'))



ziadm
Specialist
Specialist

Try to format your excel sheet column by changing it from Text type to date Type

Click on the excel column and right clik -- format them choose date

jonathandienst
Partner - Champion III
Partner - Champion III

naresh kumar wrote:

In my case the data is like('DD/MM/YYYY hh:mm:ss'),

if i am doing  Date(Orders,'MM/YYYY')  it allowing duplicates.

ex:

19/04/2007 00:00:00

19/04/2007 12:03:59,

because of that i am using date# function:date#(Date(Orders,'MM/YYYY'))

That does not work - you need to strip the time value and day number from your Order field if you want to show months only:

     Date(MonthStart(Orders), 'MM/YYYY')

will not have duplicates.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
jonathandienst
Partner - Champion III
Partner - Champion III

See

QlikView Date fields

Why don’t my dates work?

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
qlikmsg4u
Specialist
Specialist

Use this, this will solve your problem

LOAD date(orders) as OrderDate,

date(floor(orders),'MM/YYYY') as Orders1

from source

jonathandienst
Partner - Champion III
Partner - Champion III

That will have 30 identical entries for each month...

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
qlikmsg4u
Specialist
Specialist

Hijontydkpi

No,I did't get that much records.

jonathandienst
Partner - Champion III
Partner - Champion III

Sure you didn't - that is just test data with only a few fact lines - but you are getting duplicates:

t1.png

If you have facts for 30 days in a month, then you will get 30 entries in Orders1 for that month.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein