Date: Thu, 21 Nov 1996 13:32:22 -0500 From: Archie Warnock To: Multiple recipients of list Subject: Re: Boolean queries via zclient Ah... It's getting to be time for a list tutorial on the Isite RPN notation. We call it KWAQS (don't ask...). But you'll have be familiar with a bit of Z39.50 for it to make sense. A single KWAQS term is a word or phrase. Examples: water "water resources" You can attach Z39.50 attributes to a KWAQS term by listing them in brackets. There are 6 Z39.50 attributes which can be defined, and they go into the brackets as pairs - the attribute number and the attribute value. So water[1,4] say to search for the word "water" with attribute 1 (=use attribute, that is, field name) and value 4 (which is the title field in the BIB-1 attribute set). The available attributes are: 1 = use attribute 2 = relation attribute 3 = position attribute 4 = structure attribute 5 = truncation attribute 6 = completeness attribute See the Z39.50 standard, appendix ATR for the full details. A more general KWAQS term would look like this "water resources[1,62,2,3,3,3,4,1,5,100]" and is interpreted as follows: Search in the abstract (use=62 - "1,62") for text equals (relation=3 - "2,3") the phrase (structure=1 - "4,1") "water resources". Search anywhere in the field (position=3 - "3,3"), do no truncation (truncation=100, "5,100"). Completeness attribute is unspecified. Now, once you know how to build a KWAQS term, you can build up Boolean combinations of them like this: OP(term1,term2) For example: AND(water[1,4],water resources[1,62,2,3,3,3,4,1,5,100]) takes the Boolean AND of the terms defined above. This generalizes: OR(AND(dog[1,4],cat[1,4]),rat[1,62]) searches for dog and cat in the title, or rat in the abstract. You can use this syntax for queries with zclient and izclient. If you're using zgate and zcon, zgate will build it for you from the HTML form input. -- Archie Warnock Internet: warnock@clark.net -- A/WWW Enterprises Phone/FAX: 301-854-2987 -- http://www.clark.net/pub/warnock/warnock.html -- As a matter of fact, I _do_ speak for my employer.