sql - What line is my error on? Error converting data type nvarchar to numeric -


i have sql query has couple hundred lines of code.

the query use work fine data has changed in queries underlying tables.

i getting following error message

error converting data type nvarchar numeric.

how can determine 1 of hundreds of lines of code in script causing error?

i have several dozen lines of code potentially throw error.

im thinking i'll have comment out lines suspect might causing issue , uncomment them 1 1 until find one(s) causing data type error.

is limitation of sql server 2014 tells "hey there's error somewhere in hundreds of lines of code" opposed giving actual line number of error (as other error types).

it give me line number points main select statement line (so first line of code)....

if returns records problem data , not script:

select *  yourtable  isnumeric(yourfield) <> 1 

Comments