44

After installing the release version of VS2012, I am unable to find SQL CLR proect template. How can I go about creating a project of this type.

Thanks!

1 Answer 1

72

All of the various database objects are now created inside of SQL Server database projects.

They've removed the distinction between database projects (SQL Scripts) and SQL CLR projects.

So it's just File -> New -> Project, Installed -> Templates -> SQL Server, SQL Server Database Project.

Then, if you go to Add -> New Item, you'll find various categories on the left, including (confusingly) SQL CLR and SQL CLR C#. The first is for generating SQL Scripts for adding CLR objects, the second is for creating the actual CLR objects themselves.

Sign up to request clarification or add additional context in comments.

5 Comments

"So it's just File -> New -> Project, Installed -> Templates -> SQL Server, SQL Server Database Project." Only problem is that I don`t have SQL server under templates. How do I resolve this?
@Joakim: you must install Microsoft SQL Server Data Tools if you don't have the templates (msdn.microsoft.com/en-us/data/tools.aspx)
For me: File -> New Project -> Installed -> Templates -> Other Languages -> SQL Server
I seem to have the 'sql clr' and 'sql clr vb' templates available in ssdt 2010 and ssdt 2012. I'm open to suggestions on how to get 'sql clr c#' added. Causes or solutions?
Upped for being applicable to VS 2013.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.