Le Mon, 4 May 2009 10:38:31 -0600, vince spicer <vinces1...@gmail.com> s'exprima ainsi:
> Advanced Strings searches are Regex via re module. > > EX: > > import re > > m = re.compile("(FDA.*?(approved|supported)|Ben[^\s])*") > > if m.search(Text): > print m.search(Text).group() > > > Vince This is not at all what the origial poster looks for, I guess (or maybe it didn't understand?). Regex can only match one individual sample of request expressed in a logical form with AND and OR clauses. What he wants is a module able to decode and perform logical searches. It can certainly be built on top of regex, with a layer that: * decodes logical requests * performs "sub-matches" for items in the request * then builds unions (OR) or intersections (AND) of results I do not know of anything like that for python. But it would be a nice project ;-) Denis ------ la vita e estrany _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor