Logic Problem

Module-CoreSlim 

Server Action Name- Employee DetailData Server Action

I have read the string from excel and split the string and inserting the data into database but Getting Ambigious path error while iterating list . Please find the attached oml. 

Core_Slim.oml

Hi Aman,

You need to do some thing like below . In this case you would need separate end node as you have condition end of loop without completion of it. 

Best Regards

Devendra

@Devendra Singh Baghel Sir , actually the scenario is . I am importing the data into the junction entity where i am getting the data in string form and trying to split it into list , and after converting it into the list i will compare that list.current.value with the label of static entity and get the id and then i will create my junction table i.e. expertiese2employee.


but the problem i am getting is after spliting the srting , i am unable to create junction entity. 

please provide a better suggestion .

HI Aman,

Try some thing like below.

Best regards

Devendra

Core_Slim.oml

Hi Aman,

I doubt this way you are doing the insertion, you are iterating the same excel list 4 times.

Iterate only once and do the insertion.

How: For example If your excel is giving you RoleName and in the employee table you have to insert the RoleId then create one server action which accepts the role name, filter the record based on role name and return the roleId, call this server action while iterating the list and assign this returned roleId to Employee.RollName variable.

If you wanted to do the same way you are doing at present then do something like this to resolve your issue :

 

I created two server actions : 

GetEmployeeByName - Based on the Input name it will return EmployeeId

GetExpertiseByLabel - based on the input expertise name it will return the ExpertiseId

Yes correct Agree with you @Mayank Dharmpurikar .  @Aman Vishwakarma Can you share the excel.

Best Regards

Devendra

Here is the Excel file .


SampleDataV1.xlsx

Hi Aman,

As per your excel you dont need multiple iterations of excel to record you can insert the data in single iteration as suggested by Mayank

Best Regards

Devendra

HI Aman,

Please find attached oml. Below is the image for single iteration 

Best Regards

Devendra

Core_Slim.oml

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.