schmegol Posted March 20, 2005 Posted March 20, 2005 I have a complex problem. I have a database of records with a text field that contains a 1 to 5 word phrase such as "winner circle post horse laptop" I want to search through each record's text field to find and compare another text field for a match of all of the words in the field regardless of the order they are in such as "circle winner laptop post horse" would be a match because the field contains all the words. I would like to reject matches that only contain a partial match of less than the complete word count. Anybody ever done this or have any ideas?
schmegol Posted March 20, 2005 Author Posted March 20, 2005 I have a complex problem. I have a database of records with a text field that contains a 1 to 5 word phrase such as "winner circle post horse laptop" I want to search through each record's text field to find and compare another text field for a match of all of the words in the field regardless of the order they are in such as "circle winner laptop post horse" would be a match because the field contains all the words. I would like to reject matches that only contain a partial match of less than the complete word count. Anybody ever done this or have any ideas?
schmegol Posted March 20, 2005 Author Posted March 20, 2005 I have a complex problem. I have a database of records with a text field that contains a 1 to 5 word phrase such as "winner circle post horse laptop" I want to search through each record's text field to find and compare another text field for a match of all of the words in the field regardless of the order they are in such as "circle winner laptop post horse" would be a match because the field contains all the words. I would like to reject matches that only contain a partial match of less than the complete word count. Anybody ever done this or have any ideas?
bikergeek Posted March 20, 2005 Posted March 20, 2005 That should be a straightforward find. Unless you quote the search text, FM should parse each word separately rather than as a phrase, and return all the records, and only those records, with all the words. Make a button with a script: Set Field [ global ; searchCriteriaField ] # Or define searchCriteriaField as a global Enter Find Mode Set Field [fieldBeingSearched; global] Perform Find
bikergeek Posted March 20, 2005 Posted March 20, 2005 That should be a straightforward find. Unless you quote the search text, FM should parse each word separately rather than as a phrase, and return all the records, and only those records, with all the words. Make a button with a script: Set Field [ global ; searchCriteriaField ] # Or define searchCriteriaField as a global Enter Find Mode Set Field [fieldBeingSearched; global] Perform Find
schmegol Posted March 20, 2005 Author Posted March 20, 2005 That solution will not really accomplish what I'm trying to do. If my phrase is "dish tv satelllite" and I search It would find reslults of "satellite tv dish" and also "dish satellite tv cable box" if that phrase was there. I am only interested in exact matches of the phrase words including the count of the phrase words and omitting extra words in the match.
schmegol Posted March 20, 2005 Author Posted March 20, 2005 That solution will not really accomplish what I'm trying to do. If my phrase is "dish tv satelllite" and I search It would find reslults of "satellite tv dish" and also "dish satellite tv cable box" if that phrase was there. I am only interested in exact matches of the phrase words including the count of the phrase words and omitting extra words in the match.
comment Posted March 20, 2005 Posted March 20, 2005 If I understand you correctly, you could use another calc field, cWords = WordCount ( textfield ) Then enter your search phrase in a global field and: Enter Find Mode Set Field [ textfield ; globalfield] Set Field [ cWords ; WordCount ( globalfield ) ] Perform Find
comment Posted March 20, 2005 Posted March 20, 2005 If I understand you correctly, you could use another calc field, cWords = WordCount ( textfield ) Then enter your search phrase in a global field and: Enter Find Mode Set Field [ textfield ; globalfield] Set Field [ cWords ; WordCount ( globalfield ) ] Perform Find
artypants Posted March 21, 2005 Posted March 21, 2005 you just need the find operator "=" in front of your find phrase like: "=find this exact phrase"
artypants Posted March 21, 2005 Posted March 21, 2005 you just need the find operator "=" in front of your find phrase like: "=find this exact phrase"
Recommended Posts
This topic is 7189 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now