0

Thanks in advance for reading this.

Unable to create a vNext Build for a composite SQL Server database project (that has a database reference). The Build is to push code from our on-premise TFS to a Dev database.

We're using VS 2015 Update 3 to create the SQL Server database project and we've TFS 2015 update 2.

In the SQL Server database project let's say you added a database reference called MyReference.dacpac (and the referenced dacpac sits in another TFS folder in the same Team Project):

How source control in TFS looks like:

-- MyTeam
 ---- DEV
  ------ Database
  ------ Common (where referenced dacpac is located)
  ------ BuildTest.Database

The vNext build error is:

C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\SSDT\Microsoft.Data.Tools.Schema.SqlTasks.targets(550,5): Error SQL72027: File "E:\Root\TFS2015\Dev\Database\Common\MyReference.dacpac" does not exist.

Here's part of the build definition:

enter image description here

Would appreciate any help!

8
  • Where does E: come from - is that the drive that the build agent is using, or could that be a local path a developer has checked in? Commented Nov 10, 2016 at 20:06
  • @DaveShaw, E drive I believe is on the build server that the build agent is using. Thanks! Commented Nov 10, 2016 at 20:12
  • Does the project build successfully locally? Commented Nov 11, 2016 at 8:13
  • @Cece-MSFT, yes, it builds successfully. Commented Nov 11, 2016 at 8:16
  • Can you check the "Mappings" setting under "Repository" tab of your build definition to see if the "Common" folder is included? And also check the logs to see if the file is downloaded during the Get Source Step. Commented Nov 14, 2016 at 3:01

1 Answer 1

1

To narrow down the issue, please try the items below:

  1. Check whether the MyReference.dacpac under path E:\Root\TFS2015\Dev\Database\Common on your build agent machine

  2. Log on to your build agent machine, and run the project manually with MSBuild command line, to check the result.

  3. Check how do you reference MyReference.dacpac locally, and check the source directory on your build agent machine to see whether the structure of the project is the same as local.

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

3 Comments

is build agent machine and build server two different boxes? for #2, "run the project manually' means on that box we use TFS to pull down the project? Or do we copy it to a network folder? We will need to cooperate with the TFS admin and report back. Thanks!
It depends on where your build agent deployed. Run project manually means run the project with MSBuild command line instead of TFS Build. You can try both the project get from TFS and copy the project to build agent machine.
This was also really helpful to narrow down the issue. Thank you again!

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.