Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am trying to load two attached files in QlikSense using Data Manager. I am getting below script.
[Sales2010]:
LOAD
Date(Date#([InvoiceDate], 'YYYYMMDD') ) AS [InvoiceDate],
[Sales] AS [Sales],
[Customer] AS [Customer];
LOAD [InvoiceDate],
[Sales],
[Customer]
FROM [lib://Downloads/Sales2010.csv]
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
[Sales2011]:
LOAD [InvoiceDate],
[Sales],
[Customer]
FROM [lib://Downloads/Sales2011.csv]
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
RENAME TABLE [Sales2010] TO [Sales2010-Sales2011];
I don't understand why InvoiceDate from Sales2010 is converted and InvoiceDate from Sales2011 is not getting converted to appropriate date fromat.
The date format in script is
SET DateFormat='DD/MM/YYYY';
Is this a bug ?
Regards,
MK
The Data Manager is simply not very clever yet. It's improving with each release, but still has a long way to go. In this case the magic date conversion is only applied to the first load statement. It's a bug. Hopefully it will be fixed in new release.
It seems that whichever one you load 2nd has the issue with the date not being formatted. I unfortunately am not sure what is going on with this.
Both files are having same data. I have only changed 2010 to 2011.
There should not be any issue with formatting..
when i tried with above files i got this
[Sales2010]:
LOAD
Date(Date#([InvoiceDate], 'YYYYMMDD') ) AS [InvoiceDate],
[Sales] AS [Sales],
[Customer] AS [Customer];
LOAD [InvoiceDate],
[Sales],
[Customer]
FROM [lib://Downloads/Sales2010.csv]
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
[Sales2011]:
LOAD
Date(Date#([InvoiceDate], 'YYYYMMDD') ) AS [Sales2011.InvoiceDate],
[Sales] AS [Sales2011.Sales],
[Customer] AS [Sales2011.Customer];
LOAD [InvoiceDate],
[Sales],
[Customer]
FROM [lib://Downloads/Sales2011.csv]
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
Hi Manish Kachhia,
Mate the problem here is simple. The solution is here:
[Sales2010]:
LOAD
Date(Date#([InvoiceDate], 'YYYYMMDD') ) AS [InvoiceDate],
[Sales] AS [Sales],
[Customer] AS [Customer];
LOAD [InvoiceDate],
[Sales],
[Customer]
FROM [lib://Downloads/Sales2010.csv]
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
[Sales2011]:
LOAD Date(Date#([InvoiceDate], 'YYYYMMDD') ) AS [InvoiceDate],
[Sales],
[Customer]
FROM [lib://Downloads/Sales2011.csv]
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
RENAME TABLE [Sales2010] TO [Sales2010-Sales2011];
Hope this help you mate
Regards,
MB
Have u tried using data manager?
I am not looking for solution on how to make date in proper format. I want to understand why Data Manager is not self converting both dates.
The Data Manager is simply not very clever yet. It's improving with each release, but still has a long way to go. In this case the magic date conversion is only applied to the first load statement. It's a bug. Hopefully it will be fixed in new release.
Dear Manish,
I always format the value on load script to ensure correct format as I need, ignoring the date format.
I believe a great test should be simulate on old version and Qlikview also.
Have you tried to open a case? I guess date format the should be respected, but ....
Have a great day.
yes bro