Reputation: 9009
I decided to include some SQL Scripts into VS2010 for ease of editing / access. However, I'm getting a bunch of errors now such as "SQL80001: Incorrect syntax near '8'. Expecting '(', or SELECT."
I don't expect VS to understand the file. It isn't SQL Server compliant, it's a file that is for another database vendor that have a few minor SQL syntax variations away from the norm (data types, etc).
In any case, I thought that Build Action: None (a property on the file) would ensure that the compiler didn't touch the file.
Looks like VS has an exception to the rule for files with .sql. Is there a way to turn this feature off?
Upvotes: 1
Views: 1691
Reputation: 29956
Maybe use a different file extension? As far as editing goes, VS will assume it is T-SQL (for SQL Server) and base the syntax highlighting on that, which will be wrong if the file is not T-SQL.
Upvotes: 2