6 Replies Latest reply on Oct 20, 2011 1:02 PM by JoshGurfinkel

    Setting up a portal

    JoshGurfinkel

      Title

      Setting up a portal

      Post

       I'm still pretty new to FM, so forgive me for this really basic question, but I'm having difficulty figuring out how to create a portal.

      Here are the basic steps I've been following:

      1) I create 2 new tables in the database, TEST1 and TEST2

      2) I create a field in TEST1 called "firstname" and another field in TEST2 called "FirstName".

      3) I create a relationship between the two tables, linking those two fields together.

      4) In my TEST1 layout, I have an edit box for entering content for the firstname field.

      5) In my TEST2 layout, I create a portal containing the field "firstname" from table TEST1.

      After creating new records on the TEST1 layout and entering firstname information, nothing is displayed in the portal in my TEST2 layout.  I'm sure I'm making some really dumb mistake, but I'm not sure what that might be.  Can anyone help me out?

        • 1. Re: Setting up a portal
          philmodjunk

          At what point in your process did you create records in Test2 with first name values that match what you entered in Test1?

          BTW, using names in a relationship--except for certain applications intended to make your user interface work better--is not a good idea. Names are not unique and people change their names--both situations that can cause problems when a relationship is based on names.

          • 2. Re: Setting up a portal
            JoshGurfinkel

             I did not.  The only reason I created a first name field for TEST2 was so that I could link the two tables, so that I could have a portal to TEST1 on a seperate layout.

            What I'd like to arrange, ultimately, is one layout for creating e-mail lists (each record would have a list title, and then a name and e-mail address), and another layout to display all the list titles (using a portal). If that makes any sense.

            I'm not sure if such a thing is even possible, but I was trying to work my way there starting with just figuring out how to set up a portal in the first place.

            Is there any way to do what I'm describing?  And also, just for my own understanding, does anyone know specifically why my attempt to create a portal isn't working?  I can see that it's a dumb use of a relationship, but I still don't understand exactly why it doesn't display anything...

            Thanks!

            • 3. Re: Setting up a portal
              philmodjunk

              I did not.  The only reason I created a first name field for TEST2 was so that I could link the two tables, so that I could have a portal to TEST1 on a seperate layout.

              OK, but without records in test 2, there is nothing to display in your portal to Test2. Go to the Test2 layout and create several records with "John" in the first name field. Then go to the Test 1 layout and create a record with "John" in it's first name field. You should then see "John" listed once for each record with "john" that you created in Test 2.

              Try this simple demo.

              Add a number field named, ID, to Test1. Click the options button to bring up field options and specify the serial number auto-enter option. Add a number field named ID to Test2. Then click over to the Relationships tab and change the link so that the two tables are linked by ID instead of First Name. Double click the line linking them and select "allow creation of records via this relationship" for Test2.

              Go back to Test2 on the Fields tab and add a text field named "Title".

              Go to your layout to Test 1, enter layout mode and double click the First Name field. Respecify it as "Tile" by selecthing that field from the specify field dialog that popped up when you double clicked it.

              Now return to browse mode and use new Record to create a brand new record in test 1. Try typing text into the Title field inside the portal.

              • 4. Re: Setting up a portal
                JoshGurfinkel

                Sorry, I wound up getting really busy yesterday and didn't have a chance to try this out until now.  But I really appreciate the help!

                Doing this as you describe, and entering text into the "Title" field in Test1 creates a new record in Test2 with that title.  However, if I create a new record directly in Test2, the "Title" that I input doesn't show up in my portal in Test1.  Why is this?  Or am I missing the point of the demo?

                • 5. Re: Setting up a portal
                  philmodjunk

                  In order for the record to appear in the portal, the key fields in Test1 and Test2, defined in the relationship, must have matching values.

                  With the relationship based on ID fields, you can create a record from the Test2 layout, but then you have to also enter the ID number of the Test1 record that you want to use to display it in the portal on your Test1 layout. When you enter the data directly in the portal, this matching ID number is entered for you. This is one of the ways that make a portal useful for data entry uses.

                  If you want to set the Test2 Layout up for data entry, you can format the Test2::ID field as a drop down list or pop up menu of Test1 IDs and their matching Names (If you were to add a Name field to the Test1 table). Then you can create a new Test2 record and use this field's value list to select the Test1 record to which you want to link it.

                  • 6. Re: Setting up a portal
                    JoshGurfinkel

                    Ohhhhh, the key fields have to have matching values!  That's what was throwing me off.  Alright, I think I get how portals work a bit better now.  Still not sure how I'll get this to work the way I want it to, but at least I understand what the problem is now, lol.  Thanks!