When writing SQL queries inside C# string literals (especially verbatim strings and raw string literals), it would be helpful if Visual Studio Code and C# tooling could recognize SQL content and provide:
- SQL syntax highlighting
- SQL IntelliSense
- Automatic SQL formatting
- SQL keyword capitalization (SELECT, FROM, WHERE, JOIN, etc.)
- Validation of SQL syntax inside strings
Example:
var query = """
select *
from employee
where id = 1
""";
Expected behavior:
The editor recognizes the content as SQL and optionally formats it as:
SELECT *
FROM employee
WHERE id = 1;
This would significantly improve readability and productivity for developers who frequently embed SQL queries in C# applications.
When writing SQL queries inside C# string literals (especially verbatim strings and raw string literals), it would be helpful if Visual Studio Code and C# tooling could recognize SQL content and provide:
Example:
var query = """
select *
from employee
where id = 1
""";
Expected behavior:
The editor recognizes the content as SQL and optionally formats it as:
SELECT *
FROM employee
WHERE id = 1;
This would significantly improve readability and productivity for developers who frequently embed SQL queries in C# applications.