Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Diagrams/Foreighn Keys question

Status
Not open for further replies.

TomasDill

IS-IT--Management
Sep 2, 2000
703
UA
Hi!

Novice question:
I need to create relations between 2 tables. How I can do this from Enterprise Manager? When I try to use Database Diagram, I cannot add any table. It shows 'CoInitialize has not been called.' message. What this means?
Are there other visual ways to add relation for tables except database diagram? What the best way for this.? [sig]<p>Vlad Grynchyshyn<br><a href=mailto:vgryn@softserve.lviv.ua>vgryn@softserve.lviv.ua</a><br>[/sig]
 
Good to see you here, Vlad.

You can use the ALTER TABLE statement in Query Analyzer to add a new REFERENCES constraint. [sig]<p>Robert Bradley<br><a href=mailto: > </a><br><a href= - Visual FoxPro Development</a><br> [/sig]
 
I understand how to do this by commands, but I have ~30 tables upsized from VFP and require to make RI on SQL server. I have no time to write that code for each relation, so trying to find some more easy and quick way. Unfortonately, Database Diagram does not works for me, despite I read all book I have on SQL Server.

Darn message! It also appears when I press Ctrl+C - Copy! Must be something very weird...

Vlad Grynchyshyn
vgryn@softserve.lviv.ua
 
Sorry I can't be a lot of help but I do know that I get the same problem .
Ctrl+C not working has bugged me for a while but I hadn't noticed the diagram thing before you mentioned it. Now that I check it also doesn't work.
BUT - having said that, I have noticed that when I first go into Enterprise Manager, Ctrl+C does tend to work for a while. I have just tried using Diagrams + it failed, closed down EM, re-opened it + tried it again and it worked.
May be worth a try

P.S. My trouble only began when I upgraded to Windows 2000 + reinstalled EM - it was fine before that.

Shep [sig][/sig]
 
Shep, looks like we found Win 2000 + SQL Server Enterprise Manager bug ;)
However, I don't know exact steps to reproduce. Now it works and after I created one diagram it works in all cases. [sig]<p>Vlad Grynchyshyn<br><a href=mailto:vgryn@softserve.lviv.ua>vgryn@softserve.lviv.ua</a><br>[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top