Author Topic: How to get attributes of element  (Read 2420 times)

Viet

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
How to get attributes of element
« on: July 08, 2014, 12:03:32 pm »
Hi,
I need to import and map some attribute fields from another program into EA. It's a setting for users. There is no package/element/or anything selected.
How can I query these properties (short desc., priority, phase, author, alias... of functional: Requirement, Issue, Usecase, etc...) to let user map them in setting section of my extension?

As I understand, that requirement properties (http://www.sparxsystems.com/enterprise_architect_user_guide/9.3/requirement_models/requirementproperties.html) are columns in table Requirements. So how can I query these column names?

Thank you,
Viet.
« Last Edit: July 08, 2014, 12:26:47 pm by lhviet »

qwerty

  • EA Guru
  • *****
  • Posts: 13570
  • Karma: +395/-301
  • I'm no guru at all
    • View Profile
Re: How to get attributes of element
« Reply #1 on: July 08, 2014, 08:12:57 pm »
In which way do you want to query them? For a script/add-in, a user defined search?

q.

Helmut Ortmann

  • EA User
  • **
  • Posts: 967
  • Karma: +42/-1
    • View Profile
Re: How to get attributes of element
« Reply #2 on: July 08, 2014, 08:31:25 pm »
Hi,

there are some ways to get the properties (short desc, Alias, etc.) of requirements or general of elements.

You may write an addin or script which uses the EA standard API to get access to it.

You may write a query to get the wanted information. If you use the query:

select * from t_object where object_type = 'Requirement'  
you will see all the available columns or a requirement. You may change the object_type to get other element types.

To get more eloborate information you have to dig a little deeper into the tables or API.

A great help are Thomas Kilians ebooks.

For importing information into EA have a look in the community. Geert for example has a great tool to import from Excel.

Helmut





Coaching, Training, Workshop (Addins: hoTools, Search&Replace, LineStyle)