62
Views
3
Comments
Solved
Import data from excel with foreign key

I'm trying to import data from an excel table but with no success.

I have these 3 entities:

1. Entity Module (whose data I want to import)

2. Static entity Product (with 2 records: House, Family)

3. Static entity Level (with 3 records: High, Medium, Low)

Module has the following columns/attributes:

 Name

 Description

 Product -> reference attribute: Product identifier

 Level -> reference attribute: Level identifier

How can I import/bootstrap data from Module.xls and set attributes Product and Level as 'foreign key'?

Thanks.

Kind regards,

Maria

Solution

Hi Maria,

Create those two FK columns as Integers in the Module entity and bootstrap data from the excel. 

Right click on entity --> Advanced --> Create action to bootstrap data from excel

Once data is imported from excel, update the data type of these two entity attributes to the static entity identifiers.

Thanks,

KJ

Rank: #91

Hi Maria,

see below post with solution -

https://www.outsystems.com/forums/discussion/34133/excel-import-and-add-a-foreign-key/ 


Hope this will help you.

Regards

Rahul Sahu

@maria- I am new too and tried simulating the solution. i checked the below link. 

Bootstrap foriegn keys.

Check if this helps