Book a Demo

Author Topic: Find MDG Diagrams via SQL  (Read 5560 times)

[email protected]

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
    • View Profile
Find MDG Diagrams via SQL
« on: September 24, 2015, 12:02:02 am »
How can I retrieve diagrams of a certain MDG 'type' in SQL.

I know for Elements I have to create a join between t_object and t_xref where t_xref stores the MDG Stereotype I'm looking for.

How do I do the same for diagrams (assuming the FQN of my 'type' is MDG::DIAGRAM)?

Thanks
« Last Edit: September 24, 2015, 01:17:44 am by jtowers »

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Find MDG Diagrams via SQL
« Reply #1 on: September 24, 2015, 02:27:59 am »
You need to look into t_diagram.styleex. It will contain something like MDGDgm=Archimate2::Business;

q.

[email protected]

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
    • View Profile
Re: Find MDG Diagrams via SQL
« Reply #2 on: September 24, 2015, 02:41:24 am »
Found it, thanks!

Follow-up question 1: Where will I find the short form of the 'type' as used in the diagram frame "Bdd", "Req" and the like?

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Find MDG Diagrams via SQL
« Reply #3 on: September 24, 2015, 05:32:41 am »
You need to derive it from Diagram_Type (via a table).

q.

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Find MDG Diagrams via SQL
« Reply #4 on: September 24, 2015, 08:07:01 am »
Quote
Follow-up question 1: Where will I find the short form of the 'type' as used in the diagram frame "Bdd", "Req" and the like?
For any MDG technology it's specified by the technology itself. The string isn't accessible via the API or stored in the database.

[email protected]

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
    • View Profile
Re: Find MDG Diagrams via SQL
« Reply #5 on: September 24, 2015, 07:53:50 pm »
Errrrr... OK some confusion here.

So I can understand how the digram 'kind' could be hard coded for UML & SysML, but for custom diagrams specified by an MDG, how does EA render the diagram frame if it doesn't store this information in the DB?

Does it just read the MDG data from the XML at startup and hold it in memeory?

If this is this case then presumably it has to re-generate the diagram frame (or at least the heading) every time one is required?


qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Find MDG Diagrams via SQL
« Reply #6 on: September 24, 2015, 08:06:11 pm »
Quote
Does it just read the MDG data from the XML at startup and hold it in memeory?
Yes.

q.