Hello,
Please try this:
set date format to "dd/mm/yyyyy"
alert(ttoc(ctot('21/08/2023 13:31:08.228')))
gives here result '21/08/2023 13:31:08.227' (!)
Is this bug still in latest version ?
I don't think so, at least not at the CTOD() function level. The value
of s_value here is 8.228000:
hb_retdt( y_value, m_value, d_value, h_value, n_value, s_value, 0 );
But the displayed value is:
21/08/2023 13:31:08.227
So the bug seem to be inside hb_retdt() function. Too much for me... :-(
I am not familiar with the datetime implementation, but IIYC this ie likely a floating point arithmetic limitation issue.
Il 21/08/2023 16:12, Claude R ha scritto:
Hello,
Please try this:
set date format to "dd/mm/yyyyy"
alert(ttoc(ctot('21/08/2023 13:31:08.228')))
gives here result '21/08/2023 13:31:08.227' (!)
Is this bug still in latest version ?Yes, there is. :-(
I don't know how to fix it, sorry. Ron?
--
Enrico Maria Giordano
http://www.emagsoftware.it
http://www.emagsoftware.it/emgmusic
http://www.emagsoftware.it/spectrum
http://www.emagsoftware.it/tbosg
return ( long ) ( iHour * 3600 * HB_DATETIMEINSEC + iMinute * 60 * HB_DATETIMEINSEC + dSeconds * HB_DATETIMEINSEC ); // The bug was here!!!
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 251 |
Nodes: | 16 (2 / 14) |
Uptime: | 140:05:52 |
Calls: | 5,526 |
Calls today: | 3 |
Files: | 11,671 |
Messages: | 5,096,464 |