
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Change Date Format
Hello,
I would like to change the Date Format
"2022-05-23T11:11:42.397Z"
to
"23.05.2022" (DD.MM.YYYY)
Does anyone know, how i can solve this problem?
- Subscribe by Topic:
-
Data Load Editor
-
Developers
-
dimension
-
expression
-
filter
-
General Question
-
Script
-
Set Analysis
-
Variables
-
Visualization
- « Previous Replies
-
- 1
- 2
- Next Replies »
Accepted Solutions


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No idea, because this works fine when I load it inline... perhaps something is wrong with the CSV load itself?
Load Date(Date#(Left("Created Date",10),'YYYY-MM-DD'),'DD.MM.YYYY') as [Created_Date] INLINE [
Created Date
2021-04-28T09:50:58.767Z
2021-04-22T16:34:35.533Z
2021-10-08T12:30:28.79Z
2022-02-14T09:31:13.19Z
2022-04-07T09:40:34.437Z
2022-04-19T14:43:29.353Z
2022-05-18T07:25:03.573Z
2022-05-19T13:28:12.093Z
2022-06-24T12:29:24.71Z
2022-07-05T11:21:37.703Z
2021-08-03T14:37:04.757Z
];

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Please try this once
=Date(Floor(DateTime), 'DD.MM.YYYY')
Thanks,
Saloni

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for your answer.
I tried this, but it still doesn't work. Do i have not reference to my data? I mean, at which part i can say, that this Method should been used for my field.
Thanks!


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If this is being recognized as a string, which is probably the case, you'll need to treat it as such rather than using date functions directly on it. This is where the date#() function comes in:
Date(Date#(Left(YourField,10),'YYYY-MM-DD'),'DD.MM.YYYY')

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You're right. I get my Data from an .csv-File.
I tried you're solution, but it also doesn't work. Again, no data returned.


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Then something is likely not as you described, because this works correctly when I use it in Qlik:
If the field was already recognized as a date (rather than a string), then date(Field,'DD.MM.YYYY') would work, but you said you already tried that.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Maybe i wasn't specific enough. Sorry for that!
Created Date |
2021-04-28T09:50:58.767Z |
2021-04-22T16:34:35.533Z |
2021-10-08T12:30:28.79Z |
2022-02-14T09:31:13.19Z |
2022-04-07T09:40:34.437Z |
2022-04-19T14:43:29.353Z |
2022-05-18T07:25:03.573Z |
2022-05-19T13:28:12.093Z |
2022-06-24T12:29:24.71Z |
2022-07-05T11:21:37.703Z |
2021-08-03T14:37:04.757Z |
then i am loading my data into Qlik:
LOAD
Date(Date#(Left("Created Date",10),'YYYY-MM-DD'),'DD.MM.YYYY') as [Created_Date]
FROM ...
Afterwards, i am adding my Filed [Created_Date] into my visualization and it returns Null.
Do you may need more information or can you recognize, what i am doing wrong?
Thanks!


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No idea, because this works fine when I load it inline... perhaps something is wrong with the CSV load itself?
Load Date(Date#(Left("Created Date",10),'YYYY-MM-DD'),'DD.MM.YYYY') as [Created_Date] INLINE [
Created Date
2021-04-28T09:50:58.767Z
2021-04-22T16:34:35.533Z
2021-10-08T12:30:28.79Z
2022-02-14T09:31:13.19Z
2022-04-07T09:40:34.437Z
2022-04-19T14:43:29.353Z
2022-05-18T07:25:03.573Z
2022-05-19T13:28:12.093Z
2022-06-24T12:29:24.71Z
2022-07-05T11:21:37.703Z
2021-08-03T14:37:04.757Z
];

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, It's working in my application also, first one I am calculating in table directly and other one is I am calculating in script editor

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I also think that something is wrong with the LOAD itself...
so i did this in the Visualization:
=left([Created_Date],11)
now, i did not get the format that i wanted, but at least it shows me just the date.
Thank you for your help!

- « Previous Replies
-
- 1
- 2
- Next Replies »