fawad001

Import data into the portal

Discussion created by fawad001 on Sep 12, 2018
Latest reply on Sep 13, 2018 by fawad001

@@Hi,

I want to import the records from the excel sheet into the portal by using a script.

Some details of the tables, layout and excel sheet

Start**

      - Table A and B are inter-related.

      -  Main Layout (Table A).

      -  Using the portal in the main layout (Table B).

      -  Tabel A fields are  ID, Name, Date.

      -  Table B fields are User_ID, ISBN, Quantity.

 

         Relation Ship

         Table A::ID = Table B::User_ID

 

         Excel Sheet

         Excel sheet contains two columns

         1) ISBN      2) Quantity

End**

 

 

 

A button in the main layout is used for an importing records having script trigger. In the script, I am using "Import Records" in which I am specifying the import order not giving the data source*. It successfully importing the excel sheet records(ISBN and Quantity) into the table B but the imported records are not displaying in the portal used in the main layout because User_ID(Table B) requires ID(Table A) for that purpose.

 

Now I have the following questions

 

 

1- How the ID(Table A) will be entered into the User_ID(Table B) during the importing of the records through the script for displaying in the portal.

Note: As excel sheet not containing such ID and I will not go for this solution.

 

2- Is the import order in the "Import Records" can be modified or controlled through script steps e.g. I want to change the target table dynamically with the script steps not by specifying through the options available in the "Import Records".

Note: This is for the purpose to make the "Import Records" generic for my other table importing records operations.

 

3- Is the data source* in the "Import Records" can be modified or controlled through script steps e.g. I want to select the file for the import records whenever user click the import button available in the main layout, after that the file should be preserved for the import orders.

 

4- How to check and validate those records during import which already exists. A message should appear for the already exists records during import.

 

Looking forward to the right answer.

 

Thanks

Outcomes