thoughts about a emptry string being passed as a d...
# lucee
z
thoughts about a emptry string being passed as a date param without a sql type ending up as {ts '1900-01-01 000000'} ? https://luceeserver.atlassian.net/browse/LDEV-2298?focusedCommentId=55031
https://trycf.com/gist/31f59a2fca2d23c53df10a00733d3558/lucee6-beta?theme=monokai <cfscript> writedump(dateFormat(2,"yyyy-mm-dd")) writedump(timeformat(2,"HHMMss")) </cfscript>
image.png
e
I like it, as not everything should end up as SQL formatted, if a dev wants to add the Ts:{} let them.
r
Not a fan. It should throw an error as it's invalid.
z
r
You are correct. I'm not a fan of Microsoft's decision either. I'm very opinionated on this and I'm of the opinion it should throw an error or be NULL. 🤷🏻‍♂️
z
if you set a sqltype for your params, it works fine
a
Should throw an error. Better would to set a default value for that field through the database engine.
z
if you set a sqltype it does