views:

197

answers:

1

Hi

I want to use Visual Studio snippets to generate SQL code, for example we have standard naming conventions for foreign keys etc and it would be great if I could just expand a snippet in my SQL script file.

However as far as I can tell the only languages that are supported by the Snippet manager are C#, VB J# and XML

http://msdn.microsoft.com/en-gb/library/ms171421(VS.80).aspx

Does anyone know of a way to have a snippet expand to SQL?

Derek

+1  A: 

I would recommend you consider using T4, which is built into Visual Studio.

Oleg has great examples, including one for stored procedures

dove