>>>A thought that comes to mind now is that the reaction to SET DELETED is inconsistent with the reaction to SET FILTER. No matter what filter is active, the SQL-query will ignore the filter anyway.
>>
>>There is a difference, however. SET DELETED is a global setting (for the entire current datasession, that is), whereas SET FILTER is only for a single table.
>>
>>When SELECTing from a filtered table, internally, the table is USEd AGAIN. When SELECTing with SET DELETED ON, this global setting also applies to the new instance of the table.
>>
>>Hilmar.
>
>So, I guess this one needs revision also:
>
>
> select ;
> a.*, ;
> Iif( Eof( 'b' ), 100, b.AGpercent ) as AGpercent, ;
> Iif( Eof( 'c' ), 100, c.percent ) as PTpercent ;
> from c_srf_details a ;
> left outer join c_AG b on a.empno = b.empno ;
> left outer join c_PT c on a.empno = c.empno ;
> into cursor c_ovw1
>
>
>Hmm, wonder why it has always given correct results. Or didn't it???
My latest tests confirm the fallacy. A possible solution might be:
select ;
a.*, ;
Iif( ISNULL( b.AGpercent ), 100, b.AGpercent ) as AGpercent, ;
Iif( ISNULL( c.percent ), 100, c.percent ) as PTpercent ;
from c_srf_details a ;
left outer join c_AG b on a.empno = b.empno ;
left outer join c_PT c on a.empno = c.empno ;
into cursor c_ovw1
What do the gurus think about this? (At this moment I feel like a beginner. :)
Groet,
Peter de Valença
Constructive frustration is the breeding ground of genius.
If there’s no willingness to moderate for the sake of good debate, then I have no willingness to debate at all.
Let's develop superb standards that will end the holy wars.
"There are three types of people: Alphas and Betas", said the beta decisively.
If you find this message rude or offensive or stupid, please take a step away from the keyboard and try to think calmly about an eventual a possible alternative explanation of my message.