SQL Server reports 'Invalid column name', but the column is present and the query works through management studio

前端 未结 12 634
生来不讨喜
生来不讨喜 2020-12-04 11:35

I\'ve hit a bit of an impasse. I have a query that is generated by some C# code. The query works fine in Microsoft SQL Server Management Studio whe

12条回答
  •  悲哀的现实
    2020-12-04 11:57

    If you are using variables with the same name as your column, it could be that you forgot the '@' variable marker. In an INSERT statement it will be detected as a column.

提交回复
热议问题