mf Posted September 19, 2001 Posted September 19, 2001 Is there a way to do a find by comparing 2 fields without creating a 3rd field(that would contain the result of the comparison)? for example, set field("field 1", ">= field 2") FM is not accepting this: it is not taking the value of field 2 but the actual field name...
BobWeaver Posted September 19, 2001 Posted September 19, 2001 No. Unless you want to resort to scripting, you have to make a calculated field and search for it.
mf Posted September 19, 2001 Author Posted September 19, 2001 Too bad... Again,without adding another field (the file has over 30000 records, so I am trying to avoid adding extra fields), can a date field be compared to a formula like "Today - 14"? You are probably going to give me the same answer, but I had to ask... 1124965230-Copy_and_Paste_Single_file.zip
BobWeaver Posted September 19, 2001 Posted September 19, 2001 If you want to do something like today-14, I would create a script like this: code: Enter find mode [no restore] Set Field [MyDateField, Status(CurrentDate)-14] Perform Find [no restore] That will find all record exactly 14 days old. If you want to find anything more than 14 days old, you can use this script. code: Enter find mode [no restore] Insert calculated value [select][MyDateField, "<"] Insert calculated value [MyDateField, Status(CurrentDate)-14] Perform Find [no restore] If these are frequent searches that you are doing, the script is the way to go, because you don't have to wait for records to recalculate and re-index. Also, you can use global fields to get some of the search criteria from the user and then use the script to transfer it to the appropriate fields in the find request. Globals don't take up any significant amount of room and they give the user some flexibility. [ September 19, 2001: Message edited by: BobWeaver ]
mf Posted September 19, 2001 Author Posted September 19, 2001 Excellent! I did not know about this "Insert Calculated Result", it works great. This is exactly what I needed. Thank you very much.
Recommended Posts
This topic is 8464 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