nick_jp Posted April 15, 2013 Posted April 15, 2013 Hello I have two tables, "investors" and "deals". Investors have a set of criteria that they want - entered as a checkbox Property Deals have a set of criteria that they meet - also entered as a checkbox I would like to be able to go into a deal record, input the criteria and then run a script that finds any investor who have at least one criteria matching one of the criteria checked for the deal. The two value lists are the same. More criteria will be added so I would like to not hard code the find criteria. I guess I need to do something like (pseudocode) Copy the fields checked into an array or list variable Go to investors form Enter find mode Loop For each item in the list check that field Add new record End loop Find However I'm not sure if that's the best way and if it was what the script syntax for steps 1 and 5 would look like. Any advice would be greatly appreciated. I'm using FMP Advanced 12. Thanks! Nick
MetaSys Software Posted April 15, 2013 Posted April 15, 2013 Hi, In the attached fp7 database file, we are displaying the portal of investors who have criterias matching as that of property deal. Thank you. CheckBoxFind_fmp12_sample.zip 1
bcooney Posted April 15, 2013 Posted April 15, 2013 Nick, I believe that your problem stems from a poor data model. If you have 3 tables, Investors>Deals<DealTypes, then you could easily search on the Deals table (each deal is a record that has a typeID and an InvestorID) and go to related Investors. This is why checkboxes, although easy to set up, make it very difficult to generate reports. hth, Barbara PS: Google "join tables." 1
nick_jp Posted April 15, 2013 Author Posted April 15, 2013 Hi Barbara, Sorry I should have been more clear. Data model is: Investor > Opportunity < Deal. Deal could also be thought of as "property". What I want to do is when I get a new deal (property) to search all the investors who it could work for so I know who to call or email first. The opportunity table tracks to the ongoing tasks and status of the join record. Hi Metasys, Thanks I'll take a look. Appreciate you linking it. Thanks Nick
nick_jp Posted April 15, 2013 Author Posted April 15, 2013 Metasys, This works exactly as I need it to. Thank you very much. Nick
Recommended Posts
This topic is 4241 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