Skip to content

SDK Style projects fails to build project which has a project dependency, on unresolved references #580

Closed
@meni-braun

Description

@meni-braun
  • SqlPackage or DacFx Version: <Sdk Name="Microsoft.Build.Sql" Version="1.0.0-rc3" />
  • .NET Framework (Windows-only) or .NET Core: .NET Core 8
  • Environment (local platform and source/target platforms): Local .NET Core 8 using dotnet build

Steps to Reproduce:

  1. Create A.sqlprojx with a SQL table dbo.MyTable and CREATE SCHEMA [Test] AUTHORIZATION [dbo] and 2 types:
    CREATE TYPE [Test].[MyAccounts] AS TABLE (
    AccountName varchar(200)
    )
    GO
    
    CREATE TYPE [dbo].[MyEmails] AS TABLE (
    Email varchar(100)
    )
  2. Create B.sqlprojx with multiple stored procedure to query that table, and some getting as parameter of one of the types above, and add a project reference to project A.sqlproj
  3. Build project B.sqlprojx with dotnet build B.sqlprojx
  4. The build fails with following errors:
    • Build error SQL71501: Parameter: [dbo].[MyFailingQuery1].[@myvalues] has an unresolved reference to Built-in Type [Test].[MyTest].
    • Build error SQL71501: Parameter: [Test].[MyFailingQuery6].[@myvalues] contains an unresolved reference to an object. Either the object does not exist or the reference is ambiguous because it could refer to any of the following objects:

Did this occur in prior versions? If not - which version(s) did it work in?
SQL project with reference to another project used to work, similar to these simplified ones, used to work on the original SSDT SQLproj format.

Created a small test project, demoing the issue: TestSqlProjx.zip

(build sdk)

Please advise!
Thank you!

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingdocumentationImprovements or additions to documentation

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions