Skip to main content
Announcements
Qlik Connect 2025: 3 days of full immersion in data, analytics, and AI. May 13-15 | Orlando, FL: Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

how to transform a date with scripting

Hello there,

i would like to split the following cell "date de création" into DATE and TIME, how to proceed in the Scripting...

thanks 2016-05-04_10h06_11.png

SET ThousandSep="'";
SET DecimalSep='.';
SET MoneyThousandSep="'";
SET MoneyDecimalSep='.';
SET MoneyFormat='fr. #''##0.00;fr.-#''##0.00';
SET TimeFormat='hh:mm:ss';
SET DateFormat='DD.MM.YYYY';
SET TimestampFormat='DD.MM.YYYY hh:mm:ss[.fff]';
SET MonthNames='janv.;févr.;mars;avr.;mai;juin;juil.;août;sept.;oct.;nov.;déc.';
SET DayNames='lun.;mar.;mer.;jeu.;ven.;sam.;dim.';


LOAD Nom,
Prénom,
[Adresse e-mail],
Status,
Langue,
[Champ libre 1],
[Champ libre 2],
Pays,
Date de création

FROM

(ooxml, embedded labels);

1 Solution

Accepted Solutions
sunny_talwar

Try like this:

SET ThousandSep="'";
SET DecimalSep='.';
SET MoneyThousandSep="'";
SET MoneyDecimalSep='.';
SET MoneyFormat='fr. #''##0.00;fr.-#''##0.00';
SET TimeFormat='hh:mm:ss';
SET DateFormat='DD.MM.YYYY';
SET TimestampFormat='YYYY-MM-DD hh:mm:ss';
SET MonthNames='janv.;févr.;mars;avr.;mai;juin;juil.;août;sept.;oct.;nov.;déc.';
SET DayNames='lun.;mar.;mer.;jeu.;ven.;sam.;dim.';

LOAD Nom,
Prénom,
[Adresse e-mail],
Status,
Langue,
[Champ libre 1],
[Champ libre 2],
Pays,
Date(Floor([Date de création])) as Date,

Time(Frac([Date de création])) as Time
FROM

(ooxml, embedded labels);

View solution in original post

3 Replies
sunny_talwar

Try like this:

SET ThousandSep="'";
SET DecimalSep='.';
SET MoneyThousandSep="'";
SET MoneyDecimalSep='.';
SET MoneyFormat='fr. #''##0.00;fr.-#''##0.00';
SET TimeFormat='hh:mm:ss';
SET DateFormat='DD.MM.YYYY';
SET TimestampFormat='YYYY-MM-DD hh:mm:ss';
SET MonthNames='janv.;févr.;mars;avr.;mai;juin;juil.;août;sept.;oct.;nov.;déc.';
SET DayNames='lun.;mar.;mer.;jeu.;ven.;sam.;dim.';

LOAD Nom,
Prénom,
[Adresse e-mail],
Status,
Langue,
[Champ libre 1],
[Champ libre 2],
Pays,
Date(Floor([Date de création])) as Date,

Time(Frac([Date de création])) as Time
FROM

(ooxml, embedded labels);

Not applicable
Author

Thanks great    for your support.

Anonymous
Not applicable
Author

by using the date and date # function to implemented the which format you like in that format.