Let me understand you... 

if tick is 0 the date id 0001/01/01 12:00:00? 
if yes the select do you want is 

SELECT datetime((TICK_VALUE / 1000000) - 62135553600, 'unixepoch') AS Expr1 


use that site for help! 
http://www.epochconverter.com/ 



----- "Roberto Dalmonte" <rob...@tiscali.it> escreveu: 
> In theory it should be possible to do it right now using the following 
> syntax ... 
> 
> SELECT datetime((columnAsTicks / 1000000) - 186796800, 
> 'unixepoch') AS Expr1 
> FROM Table 
> 
> ...unfortunately it doesn't work, at least the way I tried it. 
> 
> The operation is the following: 
> 1) transforms the ticks in seconds (divide ticks per 1 million); 
> 2) subtract the seconds passed from date 0001/01/01 (starting date in 
> System.DateTime) to 1970/1/1 (starting date in Unixepoch) 
> 3) Use the result with the built-in SQLite function datetime. 
> 
> This way you could build a view and be able to see a normal date instead 
> of ticks. 
> 
> Any idea? 
> Roberto 
> _______________________________________________ 
> sqlite-users mailing list 
> sqlite-users@sqlite.org 
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users 
> 

-- 

Atenciosamente/Regards, 

Israel Lins Albuquerque 
Desenvolvimento/Development 
Polibrás Brasil Software Ltda. 


_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to