Jump to content
Salesforce and other SMB Solutions are coming soon. ×

Relationship/Portal problem with Filemaker demo file?


kickarsey

Recommended Posts

I wonder if you can help me, I am learning to use Filemaker Pro 9 and I have been taking some inspiration from the free downloads on the FileMaker website. One in particular has got some very interesting relationships. It is titled "Property Boom" for estate agents to match properties to clients (and visa versa) and is available for free download from

 

http://www.filemaker.co.uk/propertyboom/

 

I do not like how the database functions in one area, but I can not figure out how to improve it. I was wondering if anyone could offer some assistance and explanation.

 

There are two main tables in this database -- properties, and contacts. The system can either match properties to contacts, or contacts to properties. There is a script on each layout to perform this and the selected results appear in a portal which is displayed on both layouts.

 

I have discovered that one script works perfectly, however the other will allow multiple identical entries to appear on the portal (regardless of whether the script is run from the local or remote layout).

 

The script to match properties to contacts works perfectly, each property which matches the search criteria is displayed, and the user manually selects the properties for this contact. If you run the script again and make identical selections the relationship recognizes duplicates and only a single entry is displayed in the portal row.

 

However if you now switch to the related record in the property layout and visit the shortlist - multiple entries will be entered in the portal for each time the script was run for a specific contact /property. This is also true when a script is run from the Property layout.

 

[ATTACH]1281[/ATTACH]

 

I suspect that the problem is with the relationship -- but I cannot work out what the problem is. Does anyone have any experience with this file and could anybody shine some light on why it does not appear to work as expected?

 

I think this file demonstrates a great technique for the user to be able to select records based on an automated search criteria between related tables -- however I clearly cannot quite get my head around how the relationship is working and what is causing this anomaly.

Link to comment
Share on other sites

I took a look at the file and it looks pretty hastily put together, theres still a fair amount of bugs and issues in it. this was one of the issues. The portal on the properties screen which shows short listed contacts is based on the wrong table occurrence (which is why it shows multiple entries for the one contact).

 

Go into layout mode, go to the short list table, double click the portal, and change its base table occurrence to:

 

Proptery_PotentialContacts

 

that will make each contact only show up once in that portal - in the same fashion as the short list portal on the contacts screen.

 

----

 

any file that will ALWAYS ask you if you REALLY want to create a record, after explicity pressing a "Create Record" button, has gotta be eyed with caution :)

Link to comment
Share on other sites

Genius!!!

 

Worked perfectly - I agree, I thought the file was a bit cranky but it answered alot of questions for me about how to manually select records between two table - This may not be the best example but at least it got me started.

 

I agree with your comments regarding the "are you sure you want to create a record" after you have click "Create New Record". A bit like having a button on a car airbag - "Are your sure?"

 

Thanks

 

Jim

Link to comment
Share on other sites



×
×
  • Create New...

Important Information

Terms of Use