Subject Re: filter on logical plus date field
From Akshat Kapoor <>
Date Thu, 6 Jan 2022 23:38:26 +0530
Newsgroups dbase.getting-started

Good Evening Rouke,
> In a table with a logical field 'returned' and a date field 'dateofrtrn' I'm getting weird results when I set a filter to not returned or isblank(dateofrtrn). I expect to see no records with a tick in the 'returned' field and also to see no records other than a blank value in the dateofrtrn field. However, I get the following (eg. of three records):
> set filt to not returned or isblank(dateofrtrn)
> list returned, dateofrtrn for recno()=2 or recno()=3 or recno()=14
> Record#  returned dateofrtrn
>         2  .F.        /  /
>         3  .F.      22/12/2013
>        14  .T.        /  /
> I expect only records like 2. Why are records 3 and 14 listed?

I have nothing to add from what Heinz or Ken have already said.

Looking at the data and the filter all the rows meet the desired results.
Row 2 meets both criterea
Row 3 not returned
row 14 isblank()

In case you want that only 1 of the conditions to be True and not to
list when both are true (Exclusive OR)

IF you want that then we will have to add a column and do some operations.

May be possible without adding columns but for that will be requiring
sql testing before I can comment. It will not work with xdml

Prepared to go into the details if you want that scenario.