csmedsrc Posted June 11, 2009 Posted June 11, 2009 I have a script that searches two fields on a table: account name and status At the start of the script I define a variable $un with the Get (Account Name) function. It then enters find mode, insert $un into the account name field, and insert "Pending" into the status field. Perform find and everything works. The problem is that when I try to extend the found set to also include the status of "Approved", I do not get the desired results. If I only add the "Approved" criteria it returns with approved records for users other than $un (it also includes $un). If I extend the found set with the criteria of status = "Approved" and account name = $un, I do not get any additional results. How can I perform a find that returns records for the user $un (the current account name) and a status of Pending or Approved?
fRESH_OiL Posted June 11, 2009 Posted June 11, 2009 You need to enter find mode, insert the text into the field and then perform a find b/c you can't use variables in a find. I know, it sucks.
csmedsrc Posted June 11, 2009 Author Posted June 11, 2009 Thanks for the info. I went with constraining the found set by omitting the one status I didn't want to see.
comment Posted June 11, 2009 Posted June 11, 2009 How can I perform a find that returns records for the user $un (the current account name) and a status of Pending or Approved? Enter Find Mode [] Set Field [ Table::AccountName ; $un ] Set Field [ Table::Status ; "Pending" ] Duplicate Record/Request Set Field [ Table::Status ; "Approved" ] Perform Find []
Recommended Posts
This topic is 6002 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