Hi!
Glad you found the solution. Don't remember to use 'union all', otherwise your query will work quite slowly because just 'union' makes a 'distinct' automatically.
Why you use recno()?
>I read read your last letter carefully, and the solution works ( mostly, in you're example the resualts were incorrect if the first X% had no matches )... I replied simply for the sake of interst.
>( and you alway seem to be the first to respod to my questions thanks again )
>
>if you're curious the solution that I used was:
>
>select *, recno() as recno from part where id like m.ending ;
>union ;
>select *, recno() as recno from part where id like m.Starting ;
>union ;
>select *, recno() as recno from part where between(id, m.Starting, m.Ending ) ;
>into cursor realtemp ;
>order by 1
>
>
>as the between() will grab all between the wildcards, but nothing like the wildcards.
>
>- jer
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.comICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs
It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.