Book a Demo

Author Topic: duplicate ea_guids in t_attribute  (Read 4343 times)

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
duplicate ea_guids in t_attribute
« on: February 17, 2010, 01:48:24 am »
Hi,

I'm trying to upgrade our model to use SQL server 2008 iso 2000.
To do so I though it would be wiser to start with a fresh database and do a project transfer.
So I created a database on the SQL2008 server with the script provided by Sparx, and I started the transfer.
After a while it stopped giving my an error on the t_attribute because of a violation of the ux_attribute_guid (the unique constraint on the t_attribute.ea_guid)

After running a query I found out that on my old sql2000 database I have ~150 guids who are shared by up to 6 attributes. (out of the 15.000 attributes).

Did anyone have this issue before (and knows a good way to solve it)?

Thanks

Geert

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: duplicate ea_guids in t_attribute
« Reply #1 on: February 17, 2010, 11:54:21 am »
Quote
[size=18]...[/size]
After running a query I found out that on my old sql2000 database I have ~150 GUIDs who are shared by up to 6 attributes. (out of the 15.000 attributes).
[size=18]...[/size]
Hi Geert,

The numbers don't seem to add up - did I misunderstand something?

To my knowledge, haven't seen it before - but, like you, how would you know until something like this happens?

As to how to get rid of it?  Assignment of new GUIDs would seem to be the only answer...  Or have I again, not "got it"?

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

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: duplicate ea_guids in t_attribute
« Reply #2 on: February 17, 2010, 12:40:05 pm »
Just a note.  The data integrity checker picks this up.  Yes, it replaces the guids to correct the problem.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: duplicate ea_guids in t_attribute
« Reply #3 on: February 17, 2010, 03:04:39 pm »
Simon,

Thanks, I was afraid the data integrity check was going to be the answer.
I'll see what happens when I run it on a copy of the model.

Paolo,

What I mean is that there are about 150 guid's who are used by more then one attribute. Some of these guid's are used by 6 attributes, most of them 'only' by 2.
In total I have about 15.000 attributes in my model.

I have no idea how this happened. The model has been around for a while, and they have been doing quite some import/export stuff on it. The only thing I can imagine is that in some earlier version the check on duplicate guids on attributes wasn't implemented yet, and that an import of an xmi file caused the duplicates.

Since the data integrity checker is build to correct this issue I must not be the first one to encounter this.

Geert

Geert

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: duplicate ea_guids in t_attribute
« Reply #4 on: February 18, 2010, 12:03:34 am »
Just tried the integrity check (using only the option "all GUIDs") and it indeed correctly all the duplicate guids on my attributes.

I have no problems now transferring my project to the new database schema in SQL 2008

Geert