Unresolved reference to Primary key in update statistics
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 460
- Forks
- 29
- Avg merge
- 4d 9h
- Merged PRs (30d)
- 7
Description
- SqlPackage or DacFx Version: 162.6.15.1
- .NET Framework (Windows-only) or .NET Core:
- Environment (local platform and source/target platforms):
**Steps to Reproduce:**
1. Within a stored procedure, we have a script to update statistics on a clustered index that is also a primary key. Eg:
This index is not recognized during build.
2. This happens only for Primary key and throw this error - Procedure: [dbo].[Update_statsProc] has an unresolved reference to object [dbo].[tablename].[PK_tablename]. [C:\buildAgent\work\2c925cf37f27a484\DBB\DBB.sqlproj]
**Did this occur in prior versions? If not - which version(s) did it work in?**
(DacFx/SqlPackage/SSMS/Azure Data Studio)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the build using the stored procedure and clustered primary-key index described in the issue, with the stated DacFx version. Trace how the SQL project resolves the UPDATE STATISTICS reference; done means the project builds without the unresolved-reference error for this primary-key case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, sql
- Domain
- build-system, databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100