Jump to content

Complex checkbox find question


This topic is 4050 days old. Please don't post here. Open a new topic instead.

Recommended Posts

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)

  1. Copy the fields checked into an array or list variable
  2. Go to investors form
  3. Enter find mode
  4. Loop
  5. For each item in the list check that field 
  6. Add new record
  7. End loop
  8. 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

 

Link to comment
Share on other sites

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."

  • Like 1
Link to comment
Share on other sites

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

Link to comment
Share on other sites

This topic is 4050 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.