Yes, that's correct. Keep in mind that

QUERY([Table2]; [ Table2] Link_T1_ID =[ Table1] T1_ID)

evaluates [Table1]t1_id when the line is executed. If there is no current
record for Table1 it evaluates to zero so the query is looking for Table2
link fields with a value of zero.

On Sat, Mar 14, 2020 at 8:05 AM wangel--- via 4D_Tech <[email protected]>
wrote:

> I have a Table1 with a field T1_ID, and a Table2 with a field Link_T1_ID.
>
> All Table1 records have T1_ID values greater than 0. In Table2 several
> records may have [ Table2] Link_T1_ID :=0.
>
> I query Table1 with Table2 where [ Table2] Link_T1_ID :=0: QUERY([Table1];[
> Table1] T1_ID =[ Table2] Link_T1_ID)
>
> And I get 0 records, as expected.
>
> I then query Table2 with Table1 where [ Table2] Link_T1_ID equals 0:
> QUERY([Table2]; [ Table2] Link_T1_ID =[ Table1] T1_ID)
>
> And I get all the Table2 records where [ Table2] Link_T1_ID :=0 ( in other
> word more records than 0 records).
>
> Is this as expected when there is no Table1 records where [ Table1]
> T1_ID:=0
> ?
>
>
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[email protected]
> **********************************************************************



-- 
Kirk Brooks
San Francisco, CA
======================
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to