Quote:Hi -
Let me see if I can clarify my comments because I would like to hear very specific examples that could be of general value to myself and others.
First, I should have clarified that my searches at this point have been within a text LED, so please keep in mind that my specific illustrations are in regard to doing a search on a text LED field. Also, I have not seen any difference in behavior (other than that expected) of performing the search in a specific field or using the universal search mode to perform the search on any or all fields.
1) No matter what situations I try to set up, I cannot get the [ character to work. I would really appreciate knowing something I could type into a text field and then retireve it using the [ and not simply using ..something.. I would like an example of something I can specifically type into a text field ... and what I would need to specifically type into the retrieve spec ... to achieve the desired result.
Specifically here is what I found will not work when using a typical wildcard search unless you bring into play the \ character.
2) If I want to find \ within a field
- \ retrieves nothing
- ..\.. retrieves nothing
- ..\\.. produces the desired result
Yes. That is correct, and is correct behavior. The backslash means "escape the following" and must be escaped to be used literally.
Quote:3) If I want to find = within a field
- = retrieves all blank records (as expected)
- ..=.. retrieves nothing
- ..\=.. produces the desired result
Yes. That is correct and correct behavior. The equal sign means "equals" and must be escaped to be used literally.
Quote:4) If I want to find & within a field
- & retrieves nothing
- ..&.. retrieves all records
- ..\&.. produces the desired result
Yes. That is correct and correct behavior. The ampersand means "and" and must be escaped to be used literally.
Quote:5) If I want to find . within a field
- . retrieves nothing
- ..... retrieves records with ending . (as does ..\.)
- ..\... produces the desired result
No. That is incorrect. A single period has no meaning to Sesame and does not need to be escaped - though a double period does.
So, if you have a field that says: "Mary.Lister" and you create a search spec for that field that says "Mary.Lister", Sesame will find the record that has that field saying "Mary.Lister" without anything being backslashed or escaped.
Quote:6) If I want to find ? within a field
- ? retrieves records with field containing one character (as expected)
- ..?.. retrieves records with non-blank field (as expected and as will /=)
- ..\?.. produces the desired result
Yes. That is correct in part, and correct behavior. The question mark means match any single character and must be escaped to match only a literal question mark.
Quote:7) If I want to find .. within a field
- .. retrieves all records including blanks
- ...... retrieves all records including blanks
- ..\.\... produces the desired result
Yes. This is correct in part, and correct behavior. a double period ("..") in a string field, represents any number of any character, and must be escaped to be used literally. Though only one backslash is necessary to escape both periods, i.e.: "\.."
Quote:So, at this point, I am basically asking for three things:
1) A precise example of how I can set up a situation where [ would be used in the retrieve spec (as discussed in point 1 above)
If your field contains: "Mary..A..Lister..Billingsham..Wadsworth" and you seek to find (specifically) "Mary A. Lister Billingsham Wadsworth" and no on else. You could either enter "Mary\..A\..Lister\..Billingsham\..Wadsworth" in your search spec, or you could enter: "[Mary..A..Lister..Billingsham..Wadsworth" in your search spec. They would both resolve to the same thing.
Quote:2) Additional examples, such as I gave (in points 2 through 7 above) of a character you could not find within a field, using a simple wildcard search and
In a string field, the following characters and sequences of characters need to be escaped to be found literally:
..
(
)
>
<
=
>=
<=
[]
{
}
~
&
;
/
MAX
MIN
?
\
Quote:3) How (in the case of 2 immediately above) you would perform the search to get the desired results.
In every case you can either preceed the command sequence with a backslash, or you can preceed the entire search spec string with a "[". If you preceed the string with a "[", you will literalize most of the command sequences in that string.