Friday, May 04, 2012 5:38 AM
My objective is a project containing all objects from 'db1' in schema 'tic'. Views in the tic schema using three part names reference views in 'db2' which references views and tables in 'db3'. There are infact 10+ db's and 1000's of objects so the web of dependancies is wide and deep.
I've created a project for each db using the wizard however I can not build any of them due to trillions of 3006 errors. I'm sure there is a smattering of circular references also. Without a dbschema file from the build the database reference I add to my initial project is effectively broken. I really am fighting the tool here.
How can I simply tell the project that a three part name (i.e: anything outside the project) is valid without laboriously fixing the 10+ models behind the references?
Monday, May 07, 2012 2:22 AM
Well I created a dbschema file using:
vsdbcmd.exe /Action:Import /ConnectionString:"Data Source=servernamesqld4;Integrated Security=True;Pooling=False;Initial Catalog=InfraCMDBDW" /ModelFile:"c:\source\InfraCMDBDW.dbschema"however just a single 3006 error persists for no good reason. What are some of the stranger or buggy reasons for getting 3006?
Monday, May 07, 2012 7:29 AMModerator
Based on your above description, I think that the root cause of your issue is that you do not add database references to the database projects correctly. For your scenario, you need to add database reference for DB2 in DB1 database project; and add database reference for DB3 in DB2 database project. Once you add the database references successfully, you should not get the SQL3006 errors.
Vicky Song [MSFT]
MSDN Community Support | Feedback to us
- Marked As Answer by Vicky SongModerator Monday, May 14, 2012 10:22 AM