Author Topic: V15.1 - RefGuid - Where's secret sauce?  (Read 1555 times)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8162
  • Karma: +231/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
V15.1 - RefGuid - Where's secret sauce?
« on: January 24, 2020, 01:10:14 pm »
So the RefGuid Tag type creates a GUID in t_objectproperties.
If I use the UI to assign the item via the Tagged Values... dialog, I get the item name (and, spuriously, the stereotype on the UI).  I check t_objectproperties and, sure enough, there's the GUID in the row.
So having been advised by Geert to use [Ctrl+Shift+T] to create Tags on multiple diagram objects, I created the RefGuid Tag on (say) 10 objects. By this process, the tags are created but have NULL values.  Not a problem, I can use direct SQL to fix the NULL to the appropriate GUID value.  I do so so that in t_objectproperties there is NO recognisable difference between the row I created via the UI and the ones I munged.  However, if I now select any munged item in the diagram (or the browser), I see the tag, but the reference is NOT displayed!  Thinking it might be an internal synchronisation problem (I'm sure we've seen many of those), I exited and re-entered.  No change!
The usual place for "Secret Sauces" is t_xref but I couldn't see anything obvious.

So the question is...
What am I NOT doing to get the UI to report the name of the item I've referred to via the GUID I placed in the tag in t_objectproperties?  That is, where's the secret sauce?

Frustrated,
Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 11824
  • Karma: +458/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #1 on: January 24, 2020, 03:25:55 pm »
That's weird. I've filled in RefGUID tagged values with the API a number of times.

I never saw something like this.

Geert

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 7718
  • Karma: +101/-18
    • View Profile
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #2 on: January 24, 2020, 03:28:17 pm »
There are two ways that they are defined.

1. The notes containing: Type=RefGUID;
2. From a profile. The secret sauce to specify that a tag has come from a profile has been discussed here in the past. It's the first half of the guid.
« Last Edit: January 24, 2020, 04:45:34 pm by Eve »
Eve

support@sparxsystems.com

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8162
  • Karma: +231/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #3 on: January 24, 2020, 05:18:40 pm »
There are two ways that they are defined.

1. The notes containing: Type=RefGUID;
2. From a profile.
Thanks Eve,
I just created a new tag and there was NO entry in the notes field, yet it returned the name.  This is also true of the previously created tags.  Adding Type=RefGuid in the t_objectproperties Notes column makes no difference.

To add insult to injury, if I create an Autocolour Diagram Legend; it CORRECTLY picks up the GUID value and colours the item appropriately!

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8162
  • Karma: +231/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #4 on: January 24, 2020, 05:27:51 pm »
That's weird. I've filled in RefGUID tagged values with the API a number of times.

I never saw anything like this.

Geert
You and me both!  BTW, I'm populating via direct SQL injection, not the API.

However, in the past, we've defined the Tags in the Repository and merely referenced them in the profile.  Is that still valid?  Are they the same Tag?
For example, if I define IsLegalEntity as
Type=Boolean;
Default=True;

And in my profile I define
<TaggedValues>
   <Tag name="IsLegalEntity"/>
</TaggedValues>
against a stereotype, does EA still recognise them as the same thing?
in t_objectproperties, there's ONLY "IsLegalEntity" as the Tag name however I define them.

Paolo
« Last Edit: January 24, 2020, 05:37:25 pm by Paolo F Cantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 11824
  • Karma: +458/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #5 on: January 24, 2020, 06:22:09 pm »
Ah, I guess not.

You have part of your tagged value definition in the model and part in the profile.

Ideally you should define the tagged value complete in your profile.
I guess EA is becoming better at determining which tagged value belongs to which profile.

Geert

qwerty

  • EA Guru
  • *****
  • Posts: 12778
  • Karma: +363/-295
  • I'm no guru at all
    • View Profile
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #6 on: January 24, 2020, 09:28:02 pm »
I guess EA is becoming better at determining which tagged value belongs to which profile.

Geert
They use the start of the TV GUID to determine the MDG. Like so (the first part is taken from an existing TV GUID of the desired MDG):

Code: [Select]
"{FA7CEB8C-2F74-6c2f-%s}" % guid[19:]
I haven't figured out which algorithm is used and cracking it with those few examples is impossible.

q.

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8162
  • Karma: +231/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #7 on: January 25, 2020, 11:25:18 am »
Ah, I guess not.

You have part of your tagged value definition in the model and part in the profile.

Ideally, you should define the tagged value complete in your profile.
I guess EA is becoming better at determining which tagged value belongs to which profile.

Geert
Thanks Geert (and qwerty),
I agree that I want to define the Tags in the profile.  However, in the past (many versions ago), it seemed you had to define the Tag individually (in full) against each stereotype you needed it for.  This was a maintenance headache as the Tags evolved.
Defining the Tag in the repository and referencing it in the profile solved that!

Is it possible to create the definition in the profile once and refer to it in the specific stereotype (using old-style MDG - or the new model-based ones)?

Thanks for the heads-up on the MDG GUID stuff, qwerty.  You DO mean the ea_guid in t_objectproperties, yes?  I'll have a play and see if that sheds any light on what's going on.

Paolo
« Last Edit: January 25, 2020, 11:40:33 am by Paolo F Cantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

qwerty

  • EA Guru
  • *****
  • Posts: 12778
  • Karma: +363/-295
  • I'm no guru at all
    • View Profile
Re: V15.1 - RefGuid - Where's secret sauce?
« Reply #8 on: January 25, 2020, 09:07:53 pm »
Yes. I got that wisdom from one of the supporters here many years ago. Like that with guid from package and its element twin being the same. Too bad the MDG GUID prefix creation is not published. I guess my credit for any of the Sparxians is spent all the way. So that will stay a secret for all days, most likely.

q.