Cannot built SSDT project on command line
-
2012年7月3日 上午 08:32
I'm trying to build a ssdt project on the command line using the following command:
"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe" "C:\Test\DB.sqlproj" /Rebuild "Release" /project "DB" /log "C:\Test\DB.xml"
This fails with the following error in the log:
<entry>
<record>49</record>
<time>2012/07/03 07:33:27.268</time>
<type>Error</type>
<source>VisualStudio</source>
<description>CreateInstance failed for package [Microsoft SQL Server Data Tools]</description>
<guid>{00FEE386-5F9F-4577-99F4-F327FAFC0FB9}</guid>
<hr>80131604</hr>
<errorinfo>Exception has been thrown by the target of an invocation.</errorinfo>
</entry>
<entry>
<record>50</record>
<time>2012/07/03 07:33:27.282</time>
<type>Error</type>
<source>VisualStudio</source>
<description>End package load [Microsoft SQL Server Data Tools]</description>
<guid>{00FEE386-5F9F-4577-99F4-F327FAFC0FB9}</guid>
<hr>80004005 - E_FAIL</hr>
<errorinfo>Exception has been thrown by the target of an invocation.</errorinfo>
</entry>I already did the following:
- Call Visual Studio with /ResetSettings
- Reinstall SSDT Web Installer
- Reinstall SP1 for Visual Studio 2010
Opening and building the same project in Visual Studio 2010 and then building manually works without any problems.
Searching for the error the only tip seems to be reinstalling Visual Studio which I would like to avoid as this is our productive build server with also Team Foundation Server installed and I am not aware of a clean way to uninstall Visual Studio including SP1.
Any ideas?
Thanks
Philipp
所有回覆
-
2012年7月3日 上午 09:41
Hi,
When building from the command-line I prefer to just use msbuild. Try:
>msbuild.exe "C:\Test\DB.sqlproj"
regards
JamieP.S. You'll need to use a Visual Studio Command Prompt so that the path to msbuild.exe is in your %PATH%.
ObjectStorageHelper<T> – A WinRT utility for Windows 8 | http://sqlblog.com/blogs/jamie_thomson/ | @jamiet | About me

- 已編輯 Jamie ThomsonMVP, Member 2012年7月3日 上午 09:42
- 已標示為解答 Philipp Avanade 2012年7月3日 上午 10:22
-
2012年7月3日 上午 10:22
Jamie,
it was my first intention to do it with msbuild, but didn't find the generated dacpac.
Now after looking at it again it mysterically worked. :-)Thanks for the tip
Philipp
-
2012年7月9日 下午 02:43擁有者Thanks guys. I've captured a bug for the original failure. We'll address it soon: Defect 986443 : Devenv build fails from the commandline

