I need to transfer data from sql 2012 to 2000 so I decide to create a file of insert using "Generate Script" in sql 2012 then Execute it in sql 2000. But one of the columns DataType is Date; The Sql 2012 generates Date like this:
CAST(0x13FC0A00 AS DateTime)
But SQL 2000 throw Syntax error when executing the above code
Syntax error converting datetime from binary/varbinary string.
How can I fix this error?
Try in SQL Management Studio going
Tools
-> Options
-> SQL Server Object Explorer
-> Scripting
Set "Script for server version" to "SQL Server 2000". Then re-generate the scripts.