C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




Copy or move database diagram from for sqlserver2005


Posted Date: 16 Sep 2008    Resource Type: Articles    Category: Databases

Posted By: pankaj saha       Member Level: Bronze
Rating:     Points: 10




Hi All,
Generally we face a situation when we need to move the one Database diagram to another Database. Suppose you have created a database A which contains some database diagram and there is the same or different database B which does not contains any database diagram. Now you have to move only the database diagram of A to the B.

The entire diagram’s information is stored in the dbo.sysdiagrams.
If you wish to see the table dbo.sysdiagrams which is in System Table folder of A,then write the following statement

select * from A.dbo.sysdiagrams	 


It will list all the diagram information.

Now if you need to move or copy the all the diagrams of database A to the B then write the following sql statement and run:

insert into B.dbo.sysdiagrams 
select [name], principal_id, version,definition from A.dbo.sysdiagrams




It will copy a specific diagrams from database A to database B


insert into B.dbo.sysdiagrams
select [name],diagram_id , version,definition from A.dbo.sysdiagrams
where diagram_id =13





Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
Copy or move database diagram from for sqlserver2005  .  Copy or move database diagram for sqlserver2005  .  

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: What is transaction and ACID properties?
Previous Resource: FAQ in SQL...
Return to Discussion Resource Index
Post New Resource
Category: Databases


Post resources and earn money!
 
Related Resources



dotNet Slackers   BizTalk Adaptors    Web Design

accuconference

Contact Us    Privacy Policy    Terms Of Use