Topic: Differences in the report with equal dates in Julian format

I have the following query in a button Report(SQL):

select
employees.lastname,
employees.firstname,                                   
julianday(dateofbirth, 'localtime') - 2415018.5833333335,
julianday('now', 'localtime') - 2415018.5833333335
from                                         
employees         

The value of the DATEOFBIRTH field in the table is the same as that of the variable 'now' but in the report they are different. What is this about?

Thanks

Post's attachments

Attachment icon f3.png 18.6 kb, 38 downloads since 2018-02-06 

Re: Differences in the report with equal dates in Julian format

Please attach your project, I will test it.

Dmitry.

Re: Differences in the report with equal dates in Julian format

DriveSoft wrote:

Please attach your project, I will test it.

Post's attachments

Attachment icon TDateTime for report.zip 339.36 kb, 65 downloads since 2018-02-07 

Re: Differences in the report with equal dates in Julian format

Perhaps you have wrong time zone setting in your OS, please check it.
Also you can change calculate field:

CAST(julianday(dateofbirth, 'localtime') - 2415018 as INTEGER)  
Dmitry.

Re: Differences in the report with equal dates in Julian format

DriveSoft wrote:

Perhaps you have wrong time zone setting in your OS, please check it.
Also you can change calculate field:

CAST(julianday(dateofbirth, 'localtime') - 2415018 as INTEGER)  

CAST(julianday(dateofbirth, 'localtime') - 2415018 as INTEGER) 

Agree. It worked. Thank you very much Dmitry