I’m doing some testing on Lucee 6.1.0.243 and found that datePart milliseconds is returning the incorrect values.
datePart(‘l’, ‘2024-12-01T00:00:00.100’);
returns 100
datePart(‘l’, ‘2024-12-01T00:00:00.010’);
returns 100.
datePart(‘l’, ‘2024-12-01T00:00:00.001’);
returns 100.
Milliseconds are clearly trimmed in the same way that hours,minutes,and seconds are. This is obviously an issue, especially when the right is then padded with 0’s after the evaluation.
I’ll happily submit a patch suggestion when time allows. For now though, I just wanted to give a heads up in case someone was noticing some odd trends in report generation and ended up arguing with management that “No! They are the morons, so shut up and get out of my office.”