Retrieving Child Record without Matching Parent Record? - Clarion

This is a discussion on Retrieving Child Record without Matching Parent Record? - Clarion ; Hi, I am using C5.5W (not ABC) and have created a View with the child file as the Primary file and joining the Parent file as the secondary file with the 2 field key defined for the relationship(using the fields ...

+ Reply to Thread
Results 1 to 4 of 4

Retrieving Child Record without Matching Parent Record?

  1. Default Retrieving Child Record without Matching Parent Record?

    Hi,

    I am using C5.5W (not ABC) and have created a View with the child file
    as the Primary file and joining the Parent file as the secondary file
    with the 2 field key defined for the relationship(using the fields from
    the child file to complete the Join) and projecting the 2 fields of the
    parent file. Then if I use a filter to check for blank('') values in
    the parent fields I get no records returned. If I use the NULL function
    or compare the fields to 0 I get records returned that do have a
    matching Parent as well as the one record that I was expecting in the
    first place.

    Is it possible to create a View to do this with TopSpeed files.

    Thanks, Michael Holberton


  2. Default Re: Retrieving Child Record without Matching Parent Record?

    Here's the code I have tried:

    vwItemLoc VIEW(Item)
    JOIN(loc:kCustomer, itm:ITM_CUST, itm:ITM_LOC)
    PROJECT(loc:LOC_CUST, loc:LOC_NUM)
    END
    END

    ! vwItemLoc{PROP:Filter} = 'NULL(loc:LOC_CUST) OR NULL(loc:LOC_NUM)'
    vwItemLoc{PROP:Filter} = 'loc:LOC_CUST = '' OR loc:LOC_NUM ='''

    I want to find Item records that have a non existent Customer/Location
    combination.


  3. Default Re: Retrieving Child Record without Matching Parent Record?

    Clarion does a LeftOuter Join as a default.

    So you need to do the reverse.

    Make Customer your Primary Table.

    Then on your secondary table if blank or zero you want to include it.

    Jim Mumford


  4. Default Re: Retrieving Child Record without Matching Parent Record?

    > So you need to do the reverse.
    >
    > Make Customer your Primary Table.


    I need to find the Item records whose Customer/Location combination
    does not appear in the Location Table.


    > Then on your secondary table if blank or zero you want to include it.


    If I had the Location table as the Primary table and the Item table as
    the secondary table then wouldn't I only get Item records with matching
    Customer/Location combination in the Location table?


+ Reply to Thread

Similar Threads

  1. new Child/parent parent record in typed dataset.
    By Application Development in forum ADO DAO RDO RDS
    Replies: 0
    Last Post: 08-16-2007, 08:24 PM
  2. RE: new Child/parent parent record in typed dataset.
    By Application Development in forum ADO DAO RDO RDS
    Replies: 0
    Last Post: 08-16-2007, 08:19 PM
  3. No sealed record of birth parent (class) in C++?
    By Application Development in forum c++
    Replies: 1
    Last Post: 11-04-2006, 02:47 PM
  4. Replies: 2
    Last Post: 12-19-2005, 05:52 PM
  5. retrieving a record with MSHFlexGrid
    By Application Development in forum basic.visual
    Replies: 1
    Last Post: 01-31-2004, 02:33 PM