Icon View Incident Report

Serious Serious
Reported By: Ole Willy Tuv
Reported On: 6/10/2004
For: Version 4.08 Build 1
# 1763 LEFT and RIGHT OUTER JOINs Not Processing During-Join Conditions Properly

V4.08 does not seem to process right outer joins correctly. The following script should generate 3 rows, but only generates 1 row.

drop table if exists memory\T1;
create table memory\T1 (T1_ID integer);
insert into memory\T1 values (1);
insert into memory\T1 values (2);
insert into memory\T1 values (3);

drop table if exists memory\T2;
create table memory\T2 (T2_ID integer, FK integer);
insert into memory\T2 values (1,1);
insert into memory\T2 values (2,2);
insert into memory\T2 values (3,3);

select T1.T1_ID, T2.T2_ID
from memory\T1
--join memory\T2 on
--left outer join memory\T2 on
right outer join memory\T2 on
  T2.FK = T1.T1_ID
  and T2.FK = 2;



Comments Comments
Any non-join conditions in the JOIN clause that were for the driver table of the join were being applied as if they were in the WHERE clause, when they should have been applied only for the purposes of the join, i.e. a "during-join" condition, not an "after-join" condition. This issue only applies to outer joins, and only applies when there are non-join conditions (column <operator> constant conditions instead of column <operator> column conditions) on the driver table in an outer join. In the above example, if the T2.FK = 2 condition would have been T1.FK = 2, then there would not be an issue and DBISAM would generate the correct results.


Resolution Resolution
Fixed Problem on 6/11/2004 in version 4.09 build 1
Image