Dudley Dufort Posted February 15, 2008 Posted February 15, 2008 I have a script that finds "late pays" in a club database. In the “perform find” script step, the find criteria are; find “2007” in the “history” table/ “year” field AND omit “2008” in the same field. That works fine. I wind up with members that were active in 2007 but not in 2008. What I’d like to do is replace those specifically entered years with a “get” function. (Year(Get ( CurrentDate )))-1 and (Year(Get ( CurrentDate ))) How do I enter a calculation or get function in the find criteria dialog box to automatically find the prior year and omit the current year? Dudley
_henry_ Posted February 15, 2008 Posted February 15, 2008 Hi Dudley, Could you save first your "get" function or calculation on a $Variable. Then, do the "Perform Find" on that $Variable result?
comment Posted February 15, 2008 Posted February 15, 2008 See if this helps: http://www.fmforums.com/forum/showpost.php?post/280414/
Dudley Dufort Posted February 15, 2008 Author Posted February 15, 2008 Yes but . . There's no provision for multiple find criteria. I tried that "set field" routine in conjunction with another "set field" "constrain found set" request but couldn't get "constrain" to work as expected. Dudley
comment Posted February 15, 2008 Posted February 15, 2008 I don't see why you would need to constrain a found set in the context of a single find operation. Try something like this: Enter Find Mode [ ] Set Field [ History::Year ; Year ( Get (CurrentDate) - 1 ) ] New Request Set Field [ History::Year ; Year ( Get (CurrentDate) ) ] Omit Record Perform Find [ ]
Dudley Dufort Posted February 16, 2008 Author Posted February 16, 2008 That's perfect. Thanks!! That's exactly what I was trying to accomplish. I was using the wrong script steps and/or in the wrong sequence. Thanks again, Dudley
Recommended Posts
This topic is 6127 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