Jozsef,
I assume that you are using Rose 2002? In previous versions of Rose you could add an entry called FixDuplicateIDs to the rose.ini and set it to Yes the first time that you loaded the model with items that have duplicate ids in it. This settings would fix all duplicate ids. After that you could turn it off (by setting it to No). The Solution listed below describes this in more detail: ///// QUESTION: When opening a model, I am getting the following message: > Warning: This model has multiple objects with the same unique id. What does this mean and how can I fix this problem? ANSWER: Fix-up capability, is conditional on there being a rose.ini entry, "FixDuplicateIds=Yes". The fix entails changing the uids of units as they are read in if a duplicate uid is detected. You can resolve this error by adding the following setting to the rose.ini file. FixDuplicateIds=Yes The fix entails checking the rose.ini setting, FixDuplicateIDs, and if set, regenerate unique ids when duplicates are encountered. This rose.ini setting is not written out by default and defaults to false if not specified, so the fixup code would never execute unless you specifically set it. You need to keep the following in mind when using this feature: 1) MAKE SURE YOU FIRST DO A BACK UP BEFORE TURNING ON FIX-UP MODE. 2) It's impossible to fix references to the uids since we don't know which one the reference should point to. We have to rely on resolution by name, and if that doesn't work, some references might get resolved to the wrong model item. 3) uids are used by many code generators (stored in the source code), so changing uids could have negative impact. 4) all units should be writable and special care should be taken to do the fix-up if the unit is read-only (make it writable) 5) if unit is shared among models, make sure all models are updated or if the unit is shared by several models (make sure name hasn't changed). 6) user should turn off this setting as soon as the model is fixed up. To enable this fix: 1) Close Rose. 2) Locate rose.ini rose.ini default location under windows: NOTE: below is the DEFAULT location for rose.ini. This location can be changed by modifying the following registry setting: HKEY_CURRENT_USER\Software\Rational Software\Rose\IniFileDir Win95: rose.ini default location is in Rose's home directory (location of the rose.exe). NT: rose.ini under profiles is used. Each user (login id) will have their own profile. By default the rose.ini is stored under application_data of the profile directory of the user. C:\WINNT\Profiles\<<login_id>>\Application Data\Rational\Rose\6.0 For example if you log in as administrator, the following location is used: C:\WINNT\Orofiles\administrator\Application Data\Rational\Rose\6.0 NOTE: Making changes to rose.ini in home dir under NT has NO effect! Windows 2000: rose.ini file is located in the following default location: C:\Documents and Settings\<<username>>\Application Data\Rational\Rose\6.0 NOTE: By default this is now a hidden file and directory in Windows 2000, which was not the case under NT. To see it: 1. Right-click My Computer, and then click Explore. 2. On the Tools menu, click Folder Options. 3. On the View tab, click Show hidden files and folders, and then click OK. NOTE: Making changes to rose.ini in home dir under Window 2000 has NO effect! .rose.ini location under unix: It is a hidden file in the home directory: $HOME/.rose.ini. You should see it if you do a ls -a $HOME. This file is copied from the location listed below, /rational_dir/releases/rose.6.0.9158/Rose.ini The first time you start Rose. Rose script program to confirm location of rose.ini To determine the location of rose.ini you can run the following Rose script (Tools:New Script). Sub Main MsgBox RoseApp.GetRoseIniPath() End Sub 3) Open rose.ini in text editor 4) Locate the section that beings with [Rational Rose] 5) Add the following line anywhere below [Rational Rose] section. FixDuplicateIds=Yes. Note: this setting does not currently exist i.e. FixDuplicateIds=No setting, so you must add it. 6) Save 7) Start Rose, load problem model, then File:Save When FixDuplicateIds=yes is set in the rose.ini there should be a checkbox on the save subunits dialog box. This box has to be checked in order for this to work. Units are not marked as modified will not get fixed. So you will either have to touch affected units to get the new uids written, or check the checkbox on the "Save subunits" dialog to force a save of all loaded units. Save subunits Save modified subunits of <filename>.mdl? [] Force save of unmodified subunits that are loaded and writable [Yes] [No] 8) Quit Rose and turn off this setting as soon as the model is fixed. 9) If a unit is shared among models, make sure all models can load the unit correctly after the uids have been modified. ///// So you could merge your models together with the duplicate ids present and then implement the FixDuplicateIDs solution listed above to fix any duplicate ids that you might encounter. In Rose 2002 however there is no rose.ini file. All of the settings found in the rose.ini file have now been moved to the registry. You could therefore add the FixDuplicateIDs string to the registry as described in the Solution listed below: ///// QUESTION: I have Rose 2001A/2002, and I am trying to use the "FixDuplicateIDs" to resolve ID conflicts. Tech Note 8565 describes how I can do this by adding the "FixDuplicateIDs" to the rose.ini file. However, there is no rose.ini file created when installing Rose 2001A/2002 so I created one and added the setting "FixDuplicateIDs = Yes", but that seems not to have any effect on Rose2001A/2002. ANSWER: This settings is still possible to use from the rose.ini by default, but can also be added to the registry, if this is the case then this setting in rose.ini will be ignored by Rose2001A/2002. The setting "FixDuplicateIDs" is not by default stored in the registry but if it has been added, then it has to be removed in order to use this setting from rose.ini. The locations of where the setting "FixDuplicateIDs" is stored in the registry are: [HKEY_CURRENT_USER\Software\Rational Software\rose\Rose] [HKEY_LOCAL_MACHINE\SOFTWARE\Rational Software\Rose\Rose] NOTE:Both registry keys must be created in the Windows environment, but only the [HKEY_LOCAL_MACHINE\SOFTWARE\Rational Software\Rose\Rose] needs to be created in the Unix environment. ///// I don't need to tell you this but I will anyway... BE SURE TO BACK YOUR MODEL FILES UP BEFORE IMPLEMENTING THIS SOLUTION. :) Regards Vishu ********** Annamalai "Vishu" Viswanathan -- [EMAIL PROTECTED] Rose Technical Support Engineer Rational Customer Service - Committed to Service Excellence SCP Certified: http://www.rational.com/support/scp.jsp Rational User Conference 2002.....Freedom to Create! Call for Papers Now Open at http://www.rational.com/ruc August 18-22, 2002 Lake Buena Vista, Florida ********** -----Original Message----- From: Jozsef Bedocs [mailto:[EMAIL PROTECTED]] Sent: Monday, March 04, 2002 1:36 PM To: [EMAIL PROTECTED] Subject: (ROSE) radical changes of a model Please let me explain the situation. We have a Rose model whose use case view has matured during its development in the first project. We started a new project and decided to use a copy of the first model (for all of the usual short-sited reasons). During the tailoring of the model to the new project, we discovered extensive opportunities for re-use (imagine that). Now a core model is being created, the first and new models would be specializations of the core model. Now this may seem like wonderful news; but as some of you (that have trodden this road before) may realize, we have this slight complication. We have two versions of the model whose use cases have the same ids. So we cannot merge the two models to make the relationships. What we need to do is, for each use case in the new model assign a new id and create a relation to the core use case using the old id. There are 131 use cases; so I'm not real excited about a manual solution. Any suggestions or scripts already written? We are already guilty of repeating the dis-functional cycle; don't want to be guilty of re-inventing the wheel too. Thanks in advance for any thoughts or scipts (even snipets) that can be useful. CHEERS _________________________________________________________________ MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx ************************************************************************ * Rose Forum is a public venue for ideas and discussions. * For technical support, visit http://www.rational.com/support * * Post or Reply to: [EMAIL PROTECTED] * Subscription Requests: [EMAIL PROTECTED] * Archive of messages: * http://www.rational.com/support/usergroups/rose/rose_forum.jsp * Other Requests: [EMAIL PROTECTED] * * To unsubscribe from the list, please send email * To: [EMAIL PROTECTED] * Subject: <BLANK> * Body: unsubscribe rose_forum ************************************************************************* ************************************************************************ * Rose Forum is a public venue for ideas and discussions. * For technical support, visit http://www.rational.com/support * * Post or Reply to: [EMAIL PROTECTED] * Subscription Requests: [EMAIL PROTECTED] * Archive of messages: * http://www.rational.com/support/usergroups/rose/rose_forum.jsp * Other Requests: [EMAIL PROTECTED] * * To unsubscribe from the list, please send email * To: [EMAIL PROTECTED] * Subject: <BLANK> * Body: unsubscribe rose_forum *************************************************************************