NetTalk Central

Author Topic: Need help linking parent < - >> child records, please  (Read 1712 times)

PeterPetropoulos

  • Newbie
  • *
  • Posts: 8
    • View Profile
    • Email
Need help linking parent < - >> child records, please
« on: February 07, 2025, 01:50:58 PM »
Assume a standard Customer < - >> Orders construct.
I want the API to return open orders for the requested customer.
The client requests the customer by name.
The orders are linked to the customer by a customer record number, say CUST:RecNo = ORDER:CustRecNo.
The API Returns tab lists 2 files.
File 1. Customers are filtered by 'CUST:Name = ' aName (local variable sent in the API request).  That works.
File 2. Orders should be limited to the customer record number (above).
I am getting the filter wrong.  I'm getting all of every customers' orders, not just the ones for the requested customer.
The filter on file 2 is 'ORDER:CustRecNo = ' & CUST:RecNo, which is giving me records for all customers.
Reversing them doesn't help much, either.

Question:  What is the correct filter syntax to limit the orders to the requested customer?   :-)

PeterPetropoulos

  • Newbie
  • *
  • Posts: 8
    • View Profile
    • Email
Re: Need help linking parent < - >> child records, please
« Reply #1 on: February 08, 2025, 07:33:04 AM »
Got the answer:

Do not use the filter to link the views.
Modify the view in the generated source.