0

Technical Help/Create new record in child table

Hello all. Newbie question- How can I trigger a new record creation from a parent table in a child table. i.e: I create a record in the parent table and it automatically creates a new record in the child table? Lets say my Parent table is 'Airlines' and the child table is 'CEOs of Airlines'- When I create a record called British Airways in the 'Airlines' it creates a new record in the 'CEOs of Airlines' for me to fill in all of the details about the CEO of British Aitways.

 

MAny thanks in advance

5 replies

null
    • Nick
    • 4 yrs ago
    • Reported - view

    'Airlines' table -> Trigger on Create

    ---

    let t := this;
    let c := (create 'CEOs of Airlines');
    c.(Reference_Field := t)
    end

    ---

    • Hinpack Limited
    • Alex_B
    • 4 yrs ago
    • Reported - view

    Thanks Nick - could you please explain the definition of "this" and Reference_Field

     

    Many thanks

    • Hinpack Limited
    • Alex_B
    • 4 yrs ago
    • Reported - view

    Ok- I have got what "this" means.

     

    Still stuck on Reference_Field

    • Nick
    • 4 yrs ago
    • Reported - view

    Reference_Field field is the name of the relationship between 'CEOs of Airlines' and Airlines table.

    • Hinpack Limited
    • Alex_B
    • 4 yrs ago
    • Reported - view

    Great- thank you