If you install VisualStudio to a non-standard location (I put it under \usr\bin instead of \ProgramFiles (x86)) SSDT won't work correctly. In particular, using a "System Database" like master to a SQL project will fail with lots of errors, because database objects which exist in master won't be resolved correctly when you try to use them (e.g. sys.views actually lives in master).
The solution is to put master.dacpac in the place where SSDT expects to find it:
mkdir C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\Extensions\Microsoft\SQLDB\Extensions\SqlServer\110\SqlSchemas
copy C:\usr\bin\VS2010\Common7\IDE\Extensions\Microsoft\SQLDB\Extensions\SqlServer\110\SQLSchemas\master.dacpac C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\Extensions\Microsoft\SQLDB\Extensions\SqlServer\110\SqlSchemas
copy C:\usr\bin\VS2010\Common7\IDE\Extensions\Microsoft\SQLDB\Extensions\SqlServer\110\SQLSchemas\master.dacpac C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\Extensions\Microsoft\SQLDB\Extensions\SqlServer\110\SqlSchemas
-Max
Hahahahaaaa!!! That is ME laughing at YOU, cruel world.
-Jordan Rixon
I could not love thee, dear, so much,
Loved I not Honour more.
No comments:
Post a Comment