
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
how to convert date formate:m/d/yyy to dd-mmm-yyyy
how to convert date formate:m/d/yyy to dd-mmm-yyyy
example 12/1/2012 to Dec-2012
12-1-2012 to Dec-2012

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hi
try to Modify SET DateFormat='DD/MM/YYYY'; in the first page


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
HI,
use the below exp
date(Date,'MMM-YYYY')
function


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Although you are saying dd-mmm-yyyy you are actually giving MMM-YYYY format as an example.
For 12/1/2012
DD-MMM-YYYY will show 12-Dec-2012
MMM-YYYY will show DEC-2012
Which one is that you want?


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you are referring to column A in your XLS sheet:
Date (and time) in both XLS and QlikView are stored as a number (and as long as you do not go before March 1 1900 even as the same number). How a number is formatted (in other words "shown") to you is all up to your own preferences.
Simply load your data from XLS. Use the date() function to change it into anything you like. So if you want "dd-mmm-yyyy", simply use "date(theDateField, 'dd-mmm-yyyy')".
So, conclusion, you are effectively not converting a date, you are just showing it in the format you like.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
there are 2 ways with which you can do it.
1. Set this in load editor SET DateFormat='DD/MM/YYYY'
--This will set date format to all dates in this format.
2. Set as expression only for a single field/object via expression editor - Date(<DateField>, 'DD-MMM-YYYY')
--Only the specific object will be impacted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Date(Date#('12/1/2012', 'M/D/YYYY'), 'DD-MMM-YYYY')
