DIAGRAMS

  • Hi everybody. I need some help.

    Could you tell me how in SQL Server 7.0 I can create a diagram (or graph) not forcing any relationships?

    Maybe also there are tools which you could recommend?

    Alex

  • I like Visio. I know there are a lot of tools out there but this has always worked great for me.

    As for creating one in SQL 7.0 without defining relationships, I don't believe it can be done.

    Out of curiosity, why are you opposed to having relationships established?

    David

    David

    @SQLTentmaker

    “He is no fool who gives what he cannot keep to gain that which he cannot lose” - Jim Elliot

  • David,

    Thank you for your quick response. I'll definitely look into Visio. I would prefer to have a graphic designer built in SQL Server, though.

    About your question.

    You probably heard about 'cons and pros' of building relationships between the tables.

    Our database was created a long time ago. It's huge and works fine as long as we do joins inside our sp, triggers, views and dts packages and keep creating indexes on related fields.

    My boss doesn't want to create relationships, so it wouldn't break any old links in the database.

    You know, you can agree or disagree, but sometimes it's hard to argue when your boss doesn't want something.

  • I understand about the relationships and your boss's opinion and I was hesitant in putting in the relationships question because of the potential for debate.

    As for an integrated graphic design package for creating diagrams in SQL Server, I agree, that would be nice. Visio hooks into the database using ODBC to query the DDL and pull back all pertinent information so, it does integrate fairly well.

    I'm hoping to see some other products recommended as well so that I can look at the other feature sets that are out there.

    Thanks for the reply.

    David

    David

    @SQLTentmaker

    “He is no fool who gives what he cannot keep to gain that which he cannot lose” - Jim Elliot

  • I like Visio as well. I tried using the diagram functionality in SQL Server and it just was clunky and not flexible enough. Visio hooks up to the database and can be easily updated with changes. I also think you can create a diagram with it without specifying relationships.

  • ERWin is another handy tool. It hooks into your db via ODBC much like Visio. It is especially useful for reverse engineering a db.

  • However, ErWIN doesn't use NT Auth, which is incredibly annoying. It is also expensive, but works well. I prefer ERStudio from Embarkadero Technologies. Less cost and most of the functionality or Erwin if not all.

    Steve Jones

    sjones@sqlservercentral.com

    http://www.sqlservercentral.com/columnists/sjones

  • Alex,

    In the SQL Server diagram, right click on the relationship. Uncheck the three boxes pertaining to enforcement of relationships. The relationships will not be enforced during normal processing, but will remain as documentation in the database.

    SQL Server may bark at you and make you drop the reference when you try to perform some administrative functions. If you can live with that, this approach should work.

    Bill


    Bill Bertovich
    bbertovich@interchangeusa.com

  • I got round this by creating the relationships, and then looping round them altering them to NO CHECK. It only seems to work if you create them and then alter them. If you create them with no check, it only applies it to the existing rows, and still tries to enforce the relationship for new records. I used it because we had triggers, and they kept tripping over the RI.

    It's probably the same as the previous suggestion in EM, but maybe quicker as you can loop round them all (I have a script but unfortunately not with me). You can tell if it has worked as the diagram shows 'stripey pipes' for non enforced relationships.

    HTH

Viewing 9 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic. Login to reply