Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Help with portals?


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

Recommended Posts

Posted

I read all about them.. I never used them before and have no one around me who knows FM. I'm all alone.LOL....but a bit frustrated.

I do not know how to post it, so i made a file with notes of what I would like to do. If you have a chance and a creative mind to interpret my words, please look at this file and help if you can. Thanks.

portal.zip

Posted

Hi fishbone,

Since this is in portals Forum and since you only have one real relationship, I assume you want a portal in Main showing Contacts table. But it won't work because you are joining on 6 fields (FirstName, LastName, eMail, Phone, Fax and Title) all based upon =. Firstly, if even one period is out of place, they will not match and the relatioship won't work). Secondly, you have joined on the very fields you want displayed instead of joining on a unique key.

You have one uniqueID key (Facility_Num) Auto-Enter serial in Main. You have NO uniqueID (key) in Contacts. I have no idea why you are also putting FirstName, LastName etc in Main unless it's to attempt to establish the 'unique' contact to create the portal.

Here's how it goes: Your Main File is Facility. It has Facility_Num. This is called the Parent key (when you are in the Main table). You need a Facility_Num standard text field in Contacts. It will be considered the Foreign key in Contacts. Why? Because a [color:blue]ContactID in Contacts will be considered its Primary Key. So add two fields to Contacts: ContactID (auto-enter text serial, increment by 1) and a Facility_Num text field.

Then (in your relational graph), join Main::Facility_Num to Contacts::Facility_Num using the =. Below, you will find checkboxes. Click under Contacts the 'Allow Creation of Related.' Don't click 'Delete Related Records in this table.' (see note below please.)

Now that you have the join, place a Contacts portal on a Main form layout. Select the fields you want in the portal. Do NOT put the Contacts::Facility_Num in the portal (or if you do, change it's Field Behavior to disallow entry in browse). Go back to Browse and you're all set. Now if you click into a field in the portal, a new Contact record will be created for you. And FM (sweet as it is) will insert the Main::Facility_Num into the Contacts::Facility_Num for you and create the match.

I was going to do it for you in the file, but you have no Contact records nor a Facility_Num assigned to them. I also see that your Contacts layout is no longer associated to a Contacts table. So from that Contacts layout, select Layout > Layout Setup > Show Records From (popup) and select your REAL Contacts table again. Either trash the fields or re-specify them also to Contacts.

Once this is done (smile), you'll have a real relationship working. If you get stuck, let us know. We'll help you through it. :wink2:

Note: I know, I know ... sometimes using relationship to create portal records is problematic, but it's also the most effective way to start someone understanding how relationships work.

LaRetta

Posted

If you open the file scroll down. The layout goes beyond the main frame. Laretta, I will have to check it out when I get home from work.

Thanks for your help. I will let you know if I have trouble. I know its going to take up my evening.

This topic is 6948 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.