Import excel file and update table records

Hello everyone,

Unable to import all the columns(referential integrity) into the database from excel file. I am attaching my oml file and link to check the output.

http://harika-ramadalai.outsystemscloud.com/SlimDirectory/Entry1.aspx?_ts=637121976626167819

 Can anyone say where i was been wrong in screen/server action.

Thanks in advance

Best regards,

Harika.


Hi Harika ,

Please find the attachment for reference for uploading.


Hope this will help you.


Regards,

Amreen

Hi Harika,

Try to change the datatype of attribute (referential integrity) to integer. Once it included all the columns for bootstraping change the datatype ti Id  again, 

use integertoidenifire() in assign widget to assign intger value to Id in bootstrap action and publish.


Amreen wrote:

Hi Harika ,

Please find the attachment for reference for uploading.


Hope this will help you.


Regards,

Amreen


Thanks Amreen,

 For sharing the oml. Can i get the link or slim directory application(oap)? 

Solution

Hello Harika

I checked your oml.

In your CreateEmployees() server action, the Supervisor is a text parameter, whereas the Employee entity has an attribute SupervisorEmployeeID which is of type Employee Identifier. Also this parameter is never used. 

Also in the logic where you are using CreateorUpdateEmployee, the SupervisorEmployeeID is never assigned.

To fix your problem, try mapping the Supervisor column to an integer type in the ExcelToRecordList,  and in the CreateEmployees() action, convert the Supervisor integer to an Employee Identifier using the IntegerToIdentifier() builtin function and assign it to the SupervisorEmployeeID attribute.


Hope this helps !!!

Solution

Harika Ramadalai wrote:

Amreen wrote:

Hi Harika ,

Please find the attachment for reference for uploading.


Hope this will help you.


Regards,

Amreen


Thanks Amreen,

 For sharing the oml. Can i get the link or slim directory application(oap)? 


LINK: https://amreen-shaikh.outsystemscloud.com/SlimDiary/?_ts=637122630630079294

Sending user and password by PM.

I hope this will help.


Regards,

Amreen

Amal Raj wrote:

Hello Harika

I checked your oml.

In your CreateEmployees() server action, the Supervisor is a text parameter, whereas the Employee entity has an attribute SupervisorEmployeeID which is of type Employee Identifier. Also this parameter is never used. 

Also in the logic where you are using CreateorUpdateEmployee, the SupervisorEmployeeID is never assigned.

To fix your problem, try mapping the Supervisor column to an integer type in the ExcelToRecordList,  and in the CreateEmployees() action, convert the Supervisor integer to an Employee Identifier using the IntegerToIdentifier() builtin function and assign it to the SupervisorEmployeeID attribute.


Hope this helps !!!

Thanks Amal  Sir for the suggestion I have solved the issue.


Regards Harika.R