Précédent   Forum des professionnels en informatique > Logiciels > Solutions d'entreprise > Business Intelligence > ETL > Talend
Talend Forum d'entraide sur Talend (Talend Open Studio, ...). Avant de poster --> FAQ Talend, Tutoriels Talend
Partagez cette discussion sur d'autres réseaux sociaux : Viadeo Twitter Google Facebook Digg Delicious MySpace Yahoo
Réponse Proposer ce sujet en actualité
 
Outils de la discussion
Publicité
'
Vieux 28/03/2011, 16h44   #1
Membre à l'essai
 
Inscription : septembre 2007
Messages : 61
Détails du profil
Informations forums :
Inscription : septembre 2007
Messages : 61
Points : 22
Points : 22
Par défaut Comment convertir un String en Date ?

Bonjour,

J'ai un soucis pour convertir des champs String en Date.

Le message m'indique non concordance de type et j'ai besoins de faire cette
transformation
flash22 est déconnecté   Envoyer un message privé Réponse avec citation 00
Vieux 28/03/2011, 17h27   #2
Membre émérite
 
Homme Nicolas Saumande
Architecte Décisionnel
Inscription : février 2008
Messages : 693
Détails du profil
Informations personnelles :
Nom : Homme Nicolas Saumande
Âge : 36
Localisation : France, Haute Garonne (Midi Pyrénées)

Informations professionnelles :
Activité : Architecte Décisionnel

Informations forums :
Inscription : février 2008
Messages : 693
Points : 879
Points : 879
Bonjour,

Tu peux utiliser la routine fournie par Talend : TalendDate.parseDate.
Elle s'utilise dans le champ expression d'un tMap.
Code :
1
2
Parses text FROM the beginning of the given string TO produce a date USING the given pattern AND the DEFAULT date format symbols FOR the given locale. The method may NOT USE the entire text of the given string. 
@param pattern the pattern TO parse. @param stringDate A String whose beginning should be parsed. @RETURN A Date parsed FROM the string. @throws ParseException @exception ParseException IF the beginning of the specified string cannot be parsed.
Nicolas
DevNico est déconnecté   Envoyer un message privé Réponse avec citation 00
Réponse Proposer ce sujet en actualité Cette discussion est résolue.
Outils de la discussion



Fuseau horaire GMT +2. Il est actuellement 23h54.


 
 
 
 
Partenaires

Hébergement Web