How can I do so that when creating a new record for a referenced child table it takes me to a form created from a slice


I have this form where I register information in the parent table and additionally data is added to the child table, I am using slices to create different views for the user using the same data source from a single table, I cannot figure out how to change when I go to add a new record to the child table opens the form that I decide created from a slice, it automatically takes me to the form created by appsheet for this table.

I appreciate the help the community to guide me in this! Thanks

0 8 155
8 REPLIES 8

Please try below.

In the parent table , please add a reverse reference VC called say “Child Table Form Slice” with an expression something like below. The column should be list type with element type as ref.

REF_ROWS(“Slice Name on the child tableThat You wish to base Form On”, “Parent Table Key”)

In the referenced table setting of this column, please select the above slice name ( “Slice Name on the child tableThat You wish to base Form On”) .

You wil also have a system created reverse reference column in the parent table with an expression something like

REF_ROWS(“Child Table Name”, “Parent Table Key”)

You could hide is in the parent table form where you wish the slice based child table form to open.

You can go a little deeper, because I tried to follow the instruction but still I don’t understand very well what I have to do and how to make it work.

Assuming your parent table is “Orders” and child table is “Order Details”, please

  1. Create a slice called say “Open Order Details” on the child table “Order Details”

  2. Please create a VC in the parent table with name say “Related Open Order Details” with an expression REF_ROWS(“Open Order Details”, “Order Id”)
    The other settings of this column are as below

Please ensure to include this column in the parent table form. Please replace names of parent table (in place of Orders) and child table ( in place of “Order Details” and slice “Open Order Details” as you actually have.

There must be something I’m missing because the ref_row doesn’t appear in the parent form. I show you the step by step of what I did to see what I am missing:

1)This is my parent table and it is referenced by ID_FICHA to the child table that I show in the 2nd image

  1. Below is the child table and its ref to the parent table


  2. Then create Slices for the parent table and for the child table as shown below
    Parent Table Slice:

Child Table Slice
To validate that there was no problem, I left all the columns without a filter to avoid errors and then structure everything and rule out any errors.

then create the virtual column as you suggested:


I made sure that it is added in the slice

Create a form view for “Ordenes de Compra” which is the Slice created from the parent table called “Ficha”

Part 1:


Part 2:
as you can see add the virtual column that we created earlier

All the columns appear except the referenced one that we created.

Hello @Inventarios_FOODis, i’ve reviewed your screenshots, you don’t need a slice/form view combo for the parent table for this to work, only for the child.

  • On the child table: create the slice and the appropiate form view for that slice

  • On the parent table: a virtual column referencing the slice of the child table

Yes, but I need the Slice also the parent table because there are several views to have several functions from the same parent table and that is why I should also change the way the child table is displayed

@Suvrutt_Gurjar what do you think?

Thank you for all the details. I think your overall configuration looks okay.

You have created a conditional slice “Orden de Compra” on the parent table FICHA with row filter condition, [TIPO MOVIMENTO]=“Compra” . This condition could be an issue.

I think you may want to try first test by including the VC “Related Ficha_OC” on the parent table form rather than parent table slice.

Also please take a look at the exactly similar implementation in the sample app below. The “Open Order Details” slice on child table “Order Details” and VC “Open Order Details” in the parent table “Orders” are similar implementations as yours. There is a slice “Open Orders” on the parent table as well. Please take a look at show_if on the VC “Open Order Details” and filter condition of the slice “Open Order Details” . You are also using a condition on parent table slice , so a similar condition may be needed on the child table slice as well.

Top Labels in this Space