As the title indicates:
Is there a way to turn off implicit type conversion in SQL Server?
I want the following simple SQL to generate an error
SELECT 'a' WHERE 1='1'
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There is no way to disable it.
It has been requested though: see the proposed
SET OPTION STRICT ONMS Connect request which comes from Erland SommarskogHowever, it is utterly predictable according to datatype precedence rules
Your example of a foreign key is interesting because an actual FOREIGN KEY constraint requires the same datatype, length and collation.