I have a NodeJS project, and I am trying to pass an 'UpdateDate' field using Sequelize. I am receiving the error 'Conversion failed when converting date and/or time from character string'. I have tried passing a few different things:
Date.now()
new Date().toISOString()
Neither work. Am I missing something simple? I cannot change the column definition on the table. As far as I know, passing a string such as '2016-05-23 10:39:21.000' to a SQL DateTime field works in SSMS, but it seems to be an issue when using Sequelize and Node.
Thanks
Zach
new Date().toISOString()not produce a string like:2017-11-01T14:50:33.239Zi would try and format that as YYYY-MM-DD HH:MM:SS (similar to stackoverflow.com/questions/5129624/…)