Author Topic: Possibility for same attribute with different display values?  (Read 2467 times)

bob

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
    • View Profile
Hi there,

I'm facing a requirement to have release dependent display values (initial values) of Enums (our stereotype).

Is it possible to do that? Its important, that only the display value changes not the DB-Value (Name) of the stereotypes value?

Thanks for any help in advance!,
N.O.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 8027
  • Karma: +183/-22
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Possibility for same attribute with different display values?
« Reply #1 on: May 19, 2016, 08:51:42 pm »
You'll have to explain in with a bit more detail, because I don't understand what you mean.

Geert

bob

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
    • View Profile
Re: Possibility for same attribute with different display values?
« Reply #2 on: May 19, 2016, 09:59:18 pm »
Ok I'll try :)

Well lets say we have a stereotype containing some values with aliases and initial values... Everything as usual so far no problems.

Now imagine you want to have the initial value changed in a future release but need to keep the old values because of the older releases.

Release Information is defined in the tagged values of every attribute.

I just need a way to have multiple attributes with the same name but different initial values under one Stereotype (in my case a simple enum)!

For Example:

Enum : EgEnum

Values: name type alias initialvalue
1)         val1   string v1  displayval1
2)         val2   string v2  displayval2
3)         val3   string v3  displayval3

Now i want:
4)         val3   string v3  displayval33

Another problem i just faced is that is isnt even possible anymore (in EA 11 it was, just tested) to have a different value and only the same alias and/or display value eg like that:
 
4)         val33   string v33  displayval3

In every of the described cases the error message is: Attribute with the same name alrdy exist!

qwerty

  • EA Guru
  • *****
  • Posts: 9203
  • Karma: +140/-132
  • I'm no guru at all
    • View Profile
Re: Possibility for same attribute with different display values?
« Reply #3 on: May 20, 2016, 05:20:10 am »
The message comes for good reason because attribute names must be unique. You have to re-think you problem. I would run a script to stash the old tagged values (rename them with a prefix or so) and introduce the new ones the way you need them.

q.

bob

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
    • View Profile
Re: Possibility for same attribute with different display values?
« Reply #4 on: May 22, 2016, 03:39:18 am »

I got one more question though:

Do you know of the issue that one cant even use the same Initial Value if its already beeing used as a name for any attribute?!

Is that supposed to be too? Is there maybe a workaround you know about? In v.11. EA didnt care about the Initial Value being identical to the value!


Cheers,
N.o.
« Last Edit: May 22, 2016, 06:44:25 am by bob »

qwerty

  • EA Guru
  • *****
  • Posts: 9203
  • Karma: +140/-132
  • I'm no guru at all
    • View Profile
Re: Possibility for same attribute with different display values?
« Reply #5 on: May 22, 2016, 04:04:04 am »
Initial values are just strings supplied by the user. EA does not check against what it contains.

q.

bob

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
    • View Profile
Re: Possibility for same attribute with different display values?
« Reply #6 on: May 22, 2016, 06:44:55 am »
Well try it yourself then in EA 12.1

qwerty

  • EA Guru
  • *****
  • Posts: 9203
  • Karma: +140/-132
  • I'm no guru at all
    • View Profile
Re: Possibility for same attribute with different display values?
« Reply #7 on: May 22, 2016, 08:11:41 am »
Lucky you. New user and found a bug right away 8)

Please report this silly bug using link in the Support column below.

q.