Subject RE: [IBO] Master-details link with a OR statement
Author Jason Wharton
> I just want to do a master-detail relationship with a OR statement:
>
> Table1 (master)
> NOIDTABLE1
> ...
>
> Table2 (detail)
> NOIDTABLE2
> NOIDTABLE1A
> NOIDTABLE1B
> ...
>
> I would like to show in a grid the records of table2 if
> NOIDTABLE1A=TABLE1.NOIDTABLE1
> or
> NOIDTABLE1B=TABLE1.NOIDTABLE1
>
> if I put the 2 relationships in the masterlinks box, I've got a AND
> and not a OR statement
>
> Any idea how I could do that ?

Make this your WHERE clause:

WHERE (( NOIDTABLE1A = :TABLE1.NOIDTABLE1 ) OR
( NOIDTABLE1B = :TABLE1.NOIDTABLE1 ))

Make MasterLinks property blank.

Put this in MasterParamLinks:

TABLE1.NOIDTABLE1=TABLE1.NOIDTABLE1

Make sure the MasterSource property points to the DataSource of the master
dataset.

This should work just dandy.

Let me know.

Jason Wharton
www.ibobjects.com