Search

DB Projects with same object names cannot be used as database reference (Error SQL04105) by Sideout

Closed
as By Design Help for as By Design

4
0
Sign in
to vote
Type: Bug
ID: 539211
Opened: 3/4/2010 2:49:40 PM
Access Restriction: Public
0
Workaround(s)
1
User(s) can reproduce this bug
I have a common function udf_Split in multiple databases along with a Numbers table, etc. So if I have these same named elements in database A and database B and I add a reference to B from A, I get errors like:

SQL04105: The model already has an element that has the same name dbo.udf_Split.    

I should be allowed to do this. It sounds like the internal model namespace is missing some qualifier. This is a big deal for us as we get hundreds of missing reference warnings if we can't add DB references (and ignoring the warnings misses the point because REAL warning are useful).
Details (expand)

Product Language

English

Version

Visual Studio 2010 Release Candidate

Operating System

Windows XP

Operating System Language

English

Steps to Reproduce

Create two database project with a few table and function names in common.

Try to add a database reference to the second database from the first

Note errors of type SQL04105

Actual Results

Errors of type SQL04105

Expected Results

No error
      You can indicate your satisfaction with how Microsoft handled this issue by completing this quick 3 question survey. [Details]

 

File Attachments
0 attachments
Sign in to post a comment.
Posted by Microsoft on 3/5/2010 at 2:21 PM
Sideout,

Thank you for submitting this feedback. The behavior you identify is by-design.

When establishing the reference you should provide a database name/variable to represent the referenced databases name. Without a name it becomes a composite project where multiple projects contribute to the same database. Please see these blog post/web references:

http://msdn.microsoft.com/en-us/library/bb386242.aspx
and
http://blogs.msdn.com/dukek/archive/2009/12/31/the-pros-and-cons-of-partial-projects-and-database-project-references.aspx

Thanks,

Barclay Hill

Program Manager | Visual Studio Product Team (Team Engineering - Database Tools) | Microsoft Corporation
Posted by Microsoft on 3/4/2010 at 7:05 PM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(http://support.microsoft.com)
Sign in to post a workaround.