In my ASP.NET application, everything works as expected when running it locally but when I publish the server I get the following error:
"The version of SQL Server in use does not support datatype 'datetime2'."
How can I resolve this error?
In my ASP.NET application, everything works as expected when running it locally but when I publish the server I get the following error:
"The version of SQL Server in use does not support datatype 'datetime2'."
How can I resolve this error?
If you are using Entity Framework model in your project.
Then open entity model in html or xml mode. and change ProviderManifestToken="2008"
to ProviderManifestToken="2005". after that publish on server then check and let me know.
According to this article, SQL server 2008+ supports datetime2. I am assuming your server does not run SQL 2008+ but your local SQL Express does.