Forum Discussion

ChrisBaker2's avatar
ChrisBaker2
Qrew Member
11 months ago

How to add both parent and relatled child records from one excel file import from parent table?

When I need to create a new parent record I also need to import hundreds of child records. Currently I am creating the parent record from quickbase manually, taking its created id and adding it to the excel file column for the child records before importing the file in order to link them.

Is there way for me to have the import child records button live in the parent form, or any other way to import both the parent and child records from one excel file?



------------------------------
Chris Baker
------------------------------

9 Replies

  • I would need a lot more info on the make up of the Excel document to be helpful, but in general if you have a well-maintained spreadsheet or database, you should be able to import parent records and their children. Are you using pipelines or scripting this, or something else?



    ------------------------------
    gary
    ------------------------------

    • ChrisBaker2's avatar
      ChrisBaker2
      Qrew Member

      I am not using any scripts or pipelines currently, just manually add the parent and then importing the children from an excel file that is taken from a source outside of my reach, I just get sent the final file.

      In terms of the make up, the parent table has an invoice date and due date field, and I added a uniqueId field. For the child records the file is just this structure when I import.

      Transaction Date Description Category Total UniqueId
      04/13/2022 description 1 Merchandise $25.00 fromparent
      04/13/2022 description 2 Merchandise $51.72 fromparent
      04/13/2022 description 3 Merchandise $81.55 fromparent
      04/14/2022 description 4 Merchandise $4.00 fromparent
      04/14/2022 description 5 Other Services $149.77 fromparent
      04/14/2022 description 6 Dining $23.49 fromparent


      ------------------------------
      Chris Baker
      ------------------------------
      • ChayceDuncan's avatar
        ChayceDuncan
        Qrew Captain

        If it's easy enough you could manually create the parent like you are and enter the invoice and due date, and then load a CSV with the children then save. Have a pipeline handle the loading of the children into records, this way you can skip the manual import part. 



        ------------------------------
        Chayce Duncan
        ------------------------------
  • Depending on the makeup of your parent record you could approach this with Pipelines. If you can load the file as CSV to Box or somewhere that Pipelines can access you can create the parent record and then load the actual file as the children using the prior step. The assumption there is that you have sufficient info to make the parent



    ------------------------------
    Chayce Duncan
    ------------------------------
    • AdamKrzyzanek's avatar
      AdamKrzyzanek
      Qrew Captain

      I remember I saw it on one from Empower video but not sure which (2021, 2022 or 2023).

      Over there was described how to build Excel file to load 1 set of data to "Staging" table and later pipeline was distributing it to Parent and Child table.

      Here links to recordings but not sure which🤔
      Empower-2021
      Empower-2022
      Empower 2023



      ------------------------------
      Adam Krzyzanek
      ------------------------------