Conditions Definitions (Create Lists)
When you create a review file or append records to an existing review file, you use relational operators to specify the search criteria for the records. Note: you can also use these conditions when using Global Update.
Table of Contents
- 1 Conditions
- 1.1 = (Equal to)
- 1.2 !=(Not equal to)
- 1.3 >(Greater Than) and <(Less than)
- 1.4 >= (Greater than or equal to) and <= (Less than or equal to)
- 1.5 H (Has)
- 1.6 x (Has exact)
- 1.7 A (All fields do not have)
- 1.8 O (At least one field doesn’t have)
- 1.9 W (Between)
- 1.10 N (Not within)
- 1.11 ^ (Starts with)
- 1.12 s (Starts with exact)
- 1.13 $ (Ends with)
- 1.14 z (Ends with exact)
- 1.15 e (Exists)
- 1.16 n (Not exist)
- 1.17 t (equals today)
- 1.18 y (equals yesterday)
- 1.19 v (within last week)
- 1.20 m (within last month)
- 1.21 a (is this many days ago)
- 1.22 b (is this many weeks ago)
- 1.23 c (is this many months ago)
- 1.24 j - Matches (exact) - Regular Expressions (Case-sensitive)
- 1.25 R (Matches) - Regular Expressions
- 2 Value A
- 3 Value B
- 4 Related Documentation
Conditions
= (Equal to)
The entire normalized field, including all subfields, must exactly match the characters entered.
Use for fixed-length fields -- This relational operator is useful for searching in fixed-length fields However, it is NOT recommended for searching in variable-length fields, since any difference between the search statement and the data in the field causes the system to find no match. For example, a search for "AUTHOR = Cartland Barbara" does not retrieve a record containing the MARC 100 field "Cartland, Barbara,|d1902-", since the search statement did not include subfield 'd'. Use the "has" operator for searching variable-length fields.
Use to locate item records that contain a specific course record number -- When you choose to search on the /6 COURSE ID field, use this relational operator to designate that items retrieved must contain the course record number you specify.
Use to locate records that do not contain a particular variable-length field -- You can use this relational operator to retrieve records that lack a particular variable-length field. Select this operator and do not specify any characters after the equal sign. For example, the search for "AUTHOR=" retrieves all records that do not contain an author field. Think of this as a search for "author equals nothing", which retrieves all records with no authors.
!=(Not equal to)
The normalized field does not exactly match the characters entered, that is, it has characters other than or in addition to the specified characters.
Use for fixed-length fields -- This relational operator is useful for searching fixed-length fields. For example, a search for "LOCATION != multi" retrieves all records which do not have multiple locations. Similarly, the search "LOCATION != main" retrieves records that do not have a single location of "main." However, it also retrieves records that have a location of "multi" with "main" being one of the multiple locations. To find all records that do not have "main" as a location, use the All fields do not have operator. You can search for records that have a single location of "main" using the search "LOCATION != multi AND LOCATION = main".
This operator is NOT recommended for searching variable-length fields. If you use this operator alone to search variable-length fields, the system can retrieve virtually the entire database. For example, a search for "AUTHOR != Cartland Barbara" retrieves a record containing the MARC 100 field "Cartland, Barbara,|d1902-", because subfield 'd' was not included in the search statement and therefore the two do not match exactly. This search also retrieves every other record in the database that does not have a MARC 100 field that exactly matches "Cartland Barbara." Even when you use it in combination with other, more restrictive, conditions, it is not an effective search tool for variable-length fields, since a single difference between the search statement and the data in the field can cause the system to retrieve an undesired record.
Use to locate records that do contain a particular variable-length field -- You can use this relational operator to retrieve records that contain a particular variable-length field. Select this operator and do not specify any characters after "!=". For example, the search for "AUTHOR !=" retrieves all records that do contain an author field. Think of this as a search for "author not equal to nothing", which retrieves all records with an author.
>(Greater Than) and <(Less than)
These relational operators perform a character-by-character comparison between the search statement and the data in the specified field, starting with the leftmost character in each. The system stops the comparison when the first non-matching character is reached. For the "greater than" operator, the system retrieves a record if the ASCII value of the first non-matching character is greater in the record than in the search statement. For the "less than" operator, the opposite is true. If the search statement and the data from the field are exactly equal, the record is not retrieved. For example, if a copy on order has an estimated price of $51, a search for "ESTIMATED PRICE < 50" does not retrieve that record, whereas a search for "ESTIMATED PRICE > 50" does retrieve it. Neither search retrieves a copy on order with an estimated price of $50.
If all characters in a search statement match the data in a record, but the search statement is shorter, the system considers the data in the record to be "greater than" the search statement. Thus, to search for all authors whose name begins with 'a', 'b', or 'c', enter the search statement "AUTHOR < d". Likewise, to find all authors whose name begins with 'm', enter the search "AUTHOR > m AND AUTHOR < n".
>= (Greater than or equal to) and <= (Less than or equal to)
These are the same as "greater than" and "less than" described previously, except that exact matches also are retrieved. For example, if a copy on order has an estimated price of $50, a search for "ESTIMATED PRICE >= 50" retrieves that record, as does a search for "ESTIMATED PRICE <= 50".
H (Has)
The system retrieves a record if the characters entered are contained, as a group, anywhere in any subfield of the specified field in the record. The entire group of characters must match exactly, including spaces, punctuation marks, and subfield delimiters. The field can contain additional characters. The system examines the entire field, that is, you cannot specify a particular subfield.
Use for variable-length fields -- Use the operator to find the entered characters anywhere in any subfield in the specified field. For example, searching for "AUTHOR has land" retrieves the MARC 100 fields "Landman, Paul", "Hollander, John", "Guildhall School (England)", and so forth. This is the recommended method for searching variable-length fields. Note that the search for "AUTHOR has Cartland Barbara" does not retrieve a record with the MARC 100 field "Cartland, Barbara", because the comma does not appear in the search statement.
x (Has exact)
This operator is a case-sensitive version of the H (has) operator. It functions the same but does not normalize the content of your search string or target field prior to determining matches. Consequently, if you search for "AUTHOR has Patrick", Sierra would retrieve MARC 100 fields with "Patrick, Mary" and "McPatrick, John", but not "Mcpatrick, Frank".
A (All fields do not have)
This operator retrieves records that contain the given field, provided that all occurrences of the given field do not have the specified character or string of characters.
O (At least one field doesn’t have)
This operator retrieves records that contain the given field, provided that at least one occurrence of the given field does not have the specified character or string of characters.
W (Between)
Use this operator to find a value between two specified values (entered values are included in the range). This operator usually is used for dates or amounts, for example, "ESTIMATED PRICE between 250 & 500" locates records with estimated prices between $250 and $500 (inclusive).
N (Not within)
Use this operator to find a value that is not between two specified values (entered values are included in the range). This operator usually is used for dates or amounts, for example, "CATDATE not within 01/01/93 & 12/31/93" excludes all items cataloged during 1993.
^ (Starts with)
Use this operator to find variable-length fields in which a given word or phrase appears at the beginning of the field. The comparison between the word or phrase you enter and the beginning of the field is case insensitive, thus "Journal of" and "journal of" produce the same results. This operator is not supported for fixed-length fields.
s (Starts with exact)
This operator is a case-sensitive version of the ^ (starts with) operator. It functions the same but does not normalize the content of your search string or target field prior to determining matches. Consequently, if you search for "Journal of", Sierra would not find matches for fields beginning with the string "journal of".Â
$ (Ends with)
Use this operator to find variable-length fields in which a given word or phrase appears at the end of the field. The comparison is case insensitive. Punctuation is included as part of the comparison, so if you enter "cultural studies" and a field ends with "cultural studies." (note the period), then the field would not match. This operator is not supported for fixed-length fields.
z (Ends with exact)
This operator is a case-sensitive version of the $ (ends with) operator. It functions the same but does not normalize the content of your search string or target field prior to determining matches. Consequently, if you search for "Cultural Studies", Sierra would not find matches for fields ending with the string "cultural studies".Â
e (Exists)
This operator identifies date fields, such as CAT DATE or LCHKIN, that have content (date entries).
n (Not exist)
This operator identifies blank (null) date fields.
t (equals today)
Retrieves records whose specified DATE field is equal to the day on which the search is run.
y (equals yesterday)
Retrieves records whose specified DATE field is equal to the day before the search is run.
v (within last week)
Retrieves records whose specified DATE field falls within the previous calendar week (Sunday - Saturday).
m (within last month)
Retrieves records whose specified DATE field falls within the previous calendar month (For example, if you create a review file anytime in June, you will only get the items for the month of May).
a (is this many days ago)
Retrieves records whose specified DATE field is equal to the specified number of days before the date on which the search is run.
b (is this many weeks ago)
Retrieves records whose specified DATE field is equal to the specified number of weeks before the date on which the search is run.
c (is this many months ago)
Retrieves records whose specified DATE field is equal to the specified number of months before the date on which the search is run.
j - Matches (exact) - Regular Expressions (Case-sensitive)
This operator is a case-sensitive version of the R (matches) operator. It functions the same but Sierra does not normalize the content of your search string or target field prior to determining matches.
R (Matches) - Regular Expressions
The 'r' operator enables you to enter a regular expression to search variable-length, and some fixed-length, fields in database records. Regular expressions are a powerful and complex tool that permit you to specify a pattern of characters for which to search. A regular expression can consist of ASCII characters alone or ASCII characters accompanied by special regular expression symbols.
Not all fixed-length fields can be searched using regular expressions. You can search the LOCATION, COUNTRY, HOME LIBRARY, FUND, VENDOR, LANGUAGE, and BOX NOTE fixed-length fields using regular expressions. Note that these fields are stored as five characters, right-padded with spaces, so "nor" is actually stored as "nor " (with two trailing spaces). Take care in constructing your regular expression to match this format.
When you search a field, the regular expression you use must appear somewhere in the field exactly as you specify. The regular expression does not need to match the entire field, as required by the "equal to" operator.Â
For example, the search:
TITLE matches data processing
matches records with TITLE fields containing "Modern data processing," "Data processing for beginners," and "Stretching man's mind :|ba history of data processing."
+ Â Â The plus sign is a special regular expression symbol that allows you to match one or more of the preceding characters.Â
For example, a search for:
 DESCRIPT matches x+i+Â
 matches records with DESCRIPT fields containing "xi, 318 p. ;|c18 cm.," "xii, 610, [29] p.," "xix, 374 p.," and "xxii, 314 p."
* The asterisk allows you to match zero or more of the preceding characters. For example, a search for:
 TITLE matches dea*fÂ
matches records with TITLE fields containing "Eating defensively" and "Deafness in infancy and early childhood."
. The period is a special symbol that matches any single character, including letters, numbers, spaces, and punctuation marks.Â
For example, a search for:
 AUTHOR matches j.nÂ
matches records with AUTHOR fields containing "Jones, Aubrey B," "Heise, Jon O.," and "Janaro, Richard Paul." You can combine the period with the plus sign or asterisk to search for more than a single character.Â
For example,
 AUTHOR matches j.*nÂ
 matches all of the records of the previous search as well as records containing "Couger, J. Daniel," "Diebold, John," and "Rosenberg, Jerry Martin."
[ ]Â Square brackets are special regular expression symbols that enable you to define patterns that match one of a group of alternatives (a character class).Â
For example, a search for:
AUTHOR matches jo[ah]nÂ
 matches records with AUTHOR fields containing "Johnson, Stephen M.," "Narciso, John,|d1924-," and "Fromer, Margot Joan,|d1939-."
You can use a hyphen within square brackets to specify a range of characters, for example, "[0-9]" matches any digit and "[a-z]" matches any letter. You can also combine the square brackets with the plus sign (or the asterisk) to search for a string of characters of any length:
 AUTHOR matches [a-z] manÂ
matches records with AUTHOR fields containing "Maurer, Hermann A.," "Rothman, Stanley," and "Enger, Norman L."
If the first character in the square brackets is a caret '^', then the search matches all characters that are not in the character class. See About Subfield Tags for an example of this.
{ }Â Curly braces allow you to specify that a character or pattern must occur a specific number of times.Â
For example:
TITLE matches l{3}Â
matches records with TITLE fields containing the letter 'l' appearing three times in succession, such as "illustrated". This can be useful in catching data entry errors in the database.
( )Â Parentheses create groups that can be followed by modifiers.Â
For example:
TITLE matches (the ){2}Â
matches records with TITLE fields containing the word "the" appearing twice in succession, such as "The the book of lists". This can be useful in catching data entry errors in the database.
You can combine these basic regular expression symbols to create very sophisticated search patterns. Consult a book on the UNIX egrep program to learn about other regular expression symbols and search techniques.
Value A
Enter a fixed field code value, date, or variable-length field value.
Value B
Value B is used only when specifying a range. Use Value B if using the operators W (between) or N (not within).  It is not possible to insert a value into Value B for other Boolean search conditions.
Related Documentation
-
Re-run Existing Query or Edit Existing Query for Create Lists (Sierra) (Marmot Knowledge Base)
-
Saved Searches (Create Lists) (Marmot Knowledge Base)
-
System Generated Review Files (Create Lists) (Marmot Knowledge Base)
-
In Transit Too Long Report and Create Lists Import Barcodes (Sierra) (Marmot Knowledge Base)
-
User Generated Macros (Sierra) (Marmot Knowledge Base)
-
Saved Searches, Saved Sorts, Saved Lists and Saved Exports (Create Lists) (Marmot Knowledge Base)
-
Guidelines (Create Lists) (Marmot Knowledge Base)
-
-
Sorting a Review File and Saving a Sort (Create Lists) (Marmot Knowledge Base)
-
Check Out (Circulation Desk) Item on the Fly (Sierra) (Marmot Knowledge Base)
-
Removing Duplicate Records in a Review File (Create Lists) (Marmot Knowledge Base)
-
Create a list using ISBNs (Marmot Knowledge Base)
-
Remove Records from a Review File (Global Update) (Marmot Knowledge Base)
-
Use Existing Search (Create Lists) (Marmot Knowledge Base)
-
Patron Record Fixed Length Field Definitions (Sierra) (Marmot Knowledge Base)
Â