Hi Kashyap,
> : (? (select (@Tel) ( (mob +CuSu "37 176 86303") ) ))
> @Tel={C1}
> ...
> : (? (select (@Tel) ( (mob +CuSu "37 176 86303" tel +CuSu "37 176 86303") )
> ))
> -> NIL
>
> The first query returned as expected. The second one I believe means - look
> for "37 176 86303" either in tel or in mob. I expected the second query to
> return the same result as the first query
Almost correct :)
It just needs an extra parenthesis for the combined search:
: (? (select (@C) (((mob +CuSu "37 176 86303" tel +CuSu "37 176 86303")))))
@C={C1}
-> NIL
or, to generalize it:
: (?
@Tel "37 176 86303"
(select (@C)
(((mob +CuSu @Tel tel +CuSu @Tel))) ) )
@Tel="37 176 86303" @C={C1}
or, for real usage, with the proper filter clause:
: (?
@Tel "37 176 86303"
(select (@C)
(((mob +CuSu @Tel tel +CuSu @Tel)))
(or
((fold @Tel @C mob))
((fold @Tel @C tel)) ) ) )
@Tel="37 176 86303" @C={C1}
☺/ A!ex
--
UNSUBSCRIBE: mailto:[email protected]?subject=Unsubscribe