Topic
6 replies Latest Post - ‏2012-09-13T11:42:36Z by MarkOrmos
MarkOrmos
MarkOrmos
20 Posts
ACCEPTED ANSWER

Pinned topic How to access relations on physical data models in IDA

‏2012-07-26T10:06:38Z |
Hi everybody,

I'm developing a Pluglet, where I traverse a whole Physical data model, and I also liked to access the Relations between the tables.
By now I can access the schemes, tables and columns but not the relations.
I would be very thankful if you could give me a hint.

Best regards and thanks
Mark
Updated on 2012-09-13T11:42:36Z at 2012-09-13T11:42:36Z by MarkOrmos
  • SystemAdmin
    SystemAdmin
    374 Posts
    ACCEPTED ANSWER

    Re: How to access relations on physical data models in IDA

    ‏2012-07-26T18:41:22Z  in response to MarkOrmos
    Hi Mark,

    You may want to take a look at the Constraints diagram of the SQL Model in DTP following this link http://www.eclipse.org/datatools/project_modelbase/modelbase_doc/umlJan2009/SQLModel/root.html. For example, you will find that BaseTable contains 0..n TableConstraints and ForeignKey is derived from TableConstraint. The tables in a database are BaseTables, and you may do a type cast.

    Hope it helps.
    Wei
    • MarkOrmos
      MarkOrmos
      20 Posts
      ACCEPTED ANSWER

      Re: How to access relations on physical data models in IDA

      ‏2012-07-30T12:18:15Z  in response to SystemAdmin
      Thank you Wei, you helped me a lot! Do you maybe know, how I could access the diagrams in a phyiscal data model?

      Thanks,
      Mark
      • reital
        reital
        58 Posts
        ACCEPTED ANSWER

        Re: How to access relations on physical data models in IDA

        ‏2012-07-31T04:04:18Z  in response to MarkOrmos
        Hello Mark.

        If you want to get diagrams from DataModelResource ,You can use API in
        com.ibm.datatools.diagram.core.services.IRegistrationManager.getDiagrams(Resource/File) . OR if you already got SQLObject from a physical Data Model, You can try to use API in com.ibm.datatools.diagram.core.util.DiagramHelper.

        Thanks .
        -Tao
        • MarkOrmos
          MarkOrmos
          20 Posts
          ACCEPTED ANSWER

          Re: How to access relations on physical data models in IDA

          ‏2012-08-02T11:00:14Z  in response to reital
          Thank you, you helped me a lot!

          -Mark
        • MarkOrmos
          MarkOrmos
          20 Posts
          ACCEPTED ANSWER

          Re: How to access relations on physical data models in IDA

          ‏2012-09-13T11:40:36Z  in response to reital
          Hi everybody,

          I need your help again....:)
          I would like to export the diagrams of a physical data model as image files (png, gif, whatever). From the context menu its an easy job, but I would like to do it automatically. Is there a way to access the graphics of the diagrams? Currently I traverse the diagrams with the com.ibm.datatools.diagram.core.util.DiagramHelper. Does the DiagramHelper have some functionality I could use for this job? (sorry I cant find the corresponding API).

          Best regards and thanks for your help
          -Mark
  • MarkOrmos
    MarkOrmos
    20 Posts
    ACCEPTED ANSWER

    Re: How to access relations on physical data models in IDA

    ‏2012-09-13T11:42:36Z  in response to MarkOrmos
    New question concerning diagrams. Thanks