QueryString

PWS web services that return lists of summary objects (such as PwsGetClientList) take a search string (called QueryString) as input that can be used to narrow down the results. The specific fields that the QueryString is matched against will depend upon the service in question. For example, in PwsGetClientList, the values specified in QueryString will be matched against the contents of:

  • The client name, and
  • The client number, and
  • The client name and number of all clients above a particular client in the client hierarchy

That is to say, a particular client will be considered a match not only if the QueryString matches against it's client name and/or number, but also if it is a child client of a client whose name and/or number is matched.

The QueryString is of the format of a sequence of clauses separated by vertical pipe (|) characters. Each clause is in turn a sequence of words or tokens separated by spaces. The behavior of the search operation is as follows:

  • A token or word matches on a specific instance of the entity being searched if it is found in any of the searched fields (the comparison is case-insensitive).
  • A clause matches if all words or tokens that comprise the clause match
  • The QueryString as a whole matches if one or more clauses match


Example:

The QueryString “apples oranges | bananas” would match on a specific Projector entity if the entity contained both "apples" and "oranges" in the searched fields, or if it contained "bananas".


When there are multiple fields that are included in the search (e.g. client name and client number), all fields are taken together for the purposes of the search. That is, the search term "apples oranges" will be satisfied if both words appear in any of the searched fields, or if they each appear in different fields.