Create relationships between models by importing data from Excel

Visual Paradigm’s Excel export and import allow users to import data into project. This not just for importing of model elements, but also for relationships. In this article we will show you how to create relationships between models using the Excel.

Assume we got the following ArchiMate Assessment model elements, and we would like to establish Aggregation relationships from Complaining Customers to Lack of Insight in Claim Status, Inconvenient Claim Submission, Lack of Insight in Portfolio and Incomplete and Inconsistent Information, instead of create the relationships one by one on diagram, we can do it be defining the data in Excel and import it model to generate the relationships.

Original model

Original model

To do this:

  1. Create one target relationship in your model, i.e. from Complaining Customers to Lack of Insight in Claim Status.

    Create one target relationship in model

    Create one target relationship in model

  2. Save your project.
  3. Select Project > Export > Excel.

    Select Export to Excel

    Select Export to Excel

  4. In Export to Excel dialog
      1. Specify Output path location for saving the Excel file.
      2. Select Model type per sheet as the Export Style.
      3. Select the scope for export, make sure you select the model elements you would like to define relationships no matter select Diagrams base or Model Elements

    Specify export options

    Specify export options

  5. Press Export button to export model to Excel.
  6. Open the Excel file and switch to ArchiMateAggregation sheet, only one entry show in there. It indicate the relationship is from element with ID=2 to the one with ID=6.

    ArchiMateAggregation sheet shows existing relationship in model

    ArchiMateAggregation sheet shows existing relationship in model

  7. Switch to ArchiMateAssessment sheet and we can see Complaining Customers is having ID=2, and Lack of Insight in Claim Status is having ID=6.

    Elements with relationships defined in step 1

    Elements with relationships defined in step 1

  8. Now based on this pattern we can define other relationships from 2 to 4, 5 & 7 in the ArchiMateAggregration sheet. * Please note that numeric value need to define as text from in the excel file, which is you need to add ‘ in front of the numeric data.

    Defining the from & to end of the new relationships

    Defining the from & to end of the new relationships

  9. In the Parent ID and Parent Name column we simply duplicate the data from the exported relationship.

    Specify parent columns

    Specify parent columns

  10. Switch to System Data sheet and locate the maximum number in the first column. This is the max ID of record in Excel. In our example it is 13.

    Locate max ID of excel record

    Locate max ID of excel record

  11. Switch back to ArchiMateAggregation sheet and specify the Model ID for the relationship we would like to import. In previous step we recorded the maximum ID is 13. As long as you defining the ID starting from 14 it will be fine. To play safe in our example we start form 20.

    Define Model ID

    Define Model ID

  12. Save your Excel file.
  13. Switch back to VP application and go to Project > Import > Excel.

    Import Excel

    Import Excel

  14. Select the Excel file we just edited and press Import button.
    Select Excel file to import

    Select Excel file to import


  15. The preview dialog will show the modification which will be done to the model after the import. In this case it will create three ArchiMateAggregation relationship. Press OK to proceed.

    Preview of relationship which will be import to model

    Preview of relationship which will be import to model

  16. Now the relationships are created to the model. We can right click on the model element and select Related Elements > Visualize Related Model Elements, then choose the relationship to visualize on diagram.

    Visualize imported relationships

    Visualize imported relationships

 

Related Articles

Related Links

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply