Salut
Lorsque j'utilise la fonction TIME('now') de Sqlite, celle ci semble me retourner une heure fausse ... mon téléphone étant à 12H00, il me retourne 10H00 ...
Avez vous une idée sur ce qu'il faut spécifier pour corriger ce point ?
Salut
Lorsque j'utilise la fonction TIME('now') de Sqlite, celle ci semble me retourner une heure fausse ... mon téléphone étant à 12H00, il me retourne 10H00 ...
Avez vous une idée sur ce qu'il faut spécifier pour corriger ce point ?
Bonjour,
Tu as un souci sur ton heure il faut que tu récupère l'heure en fonction de ton fuseau horaire.
http://www.sqlite.org/lang_datefunc.html
The "localtime" modifier (12) assumes the time string to its left is in Universal Coordinated Time (UTC) and adjusts the time string so that it displays localtime. If "localtime" follows a time that is not UTC, then the behavior is undefined. The "utc" is the opposite of "localtime". "utc" assumes that the string to its left is in the local timezone and adjusts that string to be in UTC. If the prior string is not in localtime, then the result of "utc" is undefined.
OK merci, c'est impecable avec localtime ...
Partager