Allow external references when exporting from managed SQL instances
- Dominant language
- C#
- Stars
- 460
- Forks
- 29
- Avg merge
- 4d 9h
- Merged PRs (30d)
- 7
Description
**Is your feature request related to a problem? Please describe.**
When calling DacServices.ExportBacpac() on a database in an Azure Managed Instance (not an Azure SQL Database), it errors out on views and procedures with references to tables outside of the current database. The multidatabase views are allowed in SQL Managed Instances. There is no way to specify the capabilities of the export target as those of a managed instance (or on prem SQL Server for that matter).
**Describe the solution you'd like**
Stop treating them as validation errors. Opt-in is fine, but ideally, detect if the source database supports them.
**Describe alternatives you've considered**
N/A, cross database views are essential to this app's functionality.
**Additional context**
Observed on DacFx 170.4.83 as seen on NuGet. .NET 8, the consumer app is an Azure function in Powershell 7.2.
Contributor guide
Research direction
Start by tracing DacServices.ExportBacpac and the validation errors raised for views and procedures with external references. Compare the capabilities of Azure Managed Instance, Azure SQL Database, and on-premises SQL Server; done means supported external references no longer block export, with an appropriate opt-in or source-capability check.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, csharp, sql
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 38/100