Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
kunkumnaveen
Specialist
Specialist

Date format

Hello,

IN  a Date field i have couple of different date formats,how to bring all them in to one format

                    DATE OF PURCHASE

                  1)Dec 11 2012 12:00AM

                  2)2-May-11,19-Jun-08

                  3)12/30/1999

                  4)Jul 19 2005 12:00AM

                  5)NULL

so those are different format i have in my date fields so how to convert in to single format ......

Thanks

Naveen

1 Solution

Accepted Solutions
Anil_Babu_Samineni

May be this?

Date(Alt(Date#([DATE OF PURCHASE], 'MMM DD YYYY hh:mmTT'), Date#([DATE OF PURCHASE], 'DD-MMM-YY'), Date#([DATE OF PURCHASE], 'MM/DD/YYYY'), IsNull([DATE OF PURCHASE])), 'DD-MM-YYYY hh:mm:ss TT') as [DATE OF PURCHASE]

More Information

alt ‒ QlikView

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

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)

View solution in original post

8 Replies
Anil_Babu_Samineni

May be this?

Date(Alt(Date#([DATE OF PURCHASE], 'MMM DD YYYY hh:mmTT'), Date#([DATE OF PURCHASE], 'DD-MMM-YY'), Date#([DATE OF PURCHASE], 'MM/DD/YYYY'), IsNull([DATE OF PURCHASE])), 'DD-MM-YYYY hh:mm:ss TT') as [DATE OF PURCHASE]

More Information

alt ‒ QlikView

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

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)
PrashantSangle

Hello,

As anil suggested alt() work for you,

but It will get difficult if you have date like 1/12/1999,12/1/1999 etc

If you know the date format then it will work good.

Regards,

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
kunkumnaveen
Specialist
Specialist
Author

Thanks Anil,it worked...

=count({<Group={'LIFESPACE'} and Group={'CLUB'} and Group={'FINANCE'}  and Group={'AD'}  >} customerid)

whats wrong with this expression i am trying to display count of customerid who is in all those four group

Anil_Babu_Samineni

Don't require and operator, Use this in set analysis. It will consider as AND only

=count({<Group={'LIFESPACE','CLUB','FINANCE','AD'} >} customerid)

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

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)
kunkumnaveen
Specialist
Specialist
Author

Anil i am looking for

                                        count of same customer based up on  customerid who bought  a different  product in all the groups 

Anil_Babu_Samineni

This is the case, you need to create one more thread with Data set and expected result. That would really helps you for further insist

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

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)
kunkumnaveen
Specialist
Specialist
Author

Ani the count as to be zero because there is no single customer who bought a product in all the four groups but after using that expression i am getting 32000 as count

Anil_Babu_Samineni

In fact, You are not showing any inputs to see. How we know whether how many you have. May be this?

=count({<Group=P(Group) >} customerid)

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

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)