February 25, 200520 yr Thanks to transpower I made progress on my FMP 7 project. However, there are two new problems I ran into and cannot yet solve satisfactory: 1) How can I display multiple records from table rows in layout rows? - I previously assumed that adding a portal would do the trick, but for some reason I cannot highlight the table to use for the record input in the portal menu. When creating fields, it merely displays the same record over and over again in the different rows. 2) This is a standard one, but with a more specific question than the postings I saw in this forum: When restricting logged in IWP users to see their records only (which have conveniently been marked with their log in name ), where do I script the if (get(username) = field, etc.)? - I assume that I have to script it in the access privilege menu, right. Also, can someone please write out the exact if (get(username)... statement, for I am not sure what to write in case 1 and case 2. Thank you so much for your previous help! This forum has done a lot to make me feel more comfortable with FMP already and I hope to further my understanding during the completion of this project. I am quite familiar with the mysql and php synergie, and have the feeling that once I am on the same level with FMP, I will not go back . THANK YOU!!
February 25, 200520 yr 1) Displaying the same record multiple times often means that the relationship being used for the portal fields and the relationship the portal is based on are not the same. Verify that they are indeed the same. Also, make sure that there is a relationship from the TO on which the layout is based to the portal's TO.
February 26, 200520 yr Author Thanks for your reply! 1)Displaying the same record multiple times often means that the relationship being used for the portal fields and the relationship the portal is based on are not the same. I actually did not use a portal yet, because when trying, the portal does not highlight the table I need to pull the records from (or any table, actually). I also think that a portal would actually only help me to display records from related tables. However, I just need multiple records from the same table that have the same control number to be displayed row by row (same way a portal displays records). Therefore, I merely dragged in fields in hopes that it would realize that I do not want to display the same record twice, but rather two different records from the same table. In plainest English, my problem is that I want to display all of the records of one table (should the records belong to the signed in user, but that's my 2nd problem) in one layout, which is a form. I just want to display all of the signed-in user's records in multiple rows.
February 28, 200520 yr Author Okay, I tried everything and still couldn't find a satisfactory way to fix my problem. I attached a screenshot of my user interface (read only form-view intended for instant web publishing) with the empty fields indicating that I would like to display all of the records from the database for that user. I cannot use a portal, since I am looking for records in only one table. Help is greatly appreciated. I already spent way too much time on this seemingly silly problem .
February 28, 200520 yr "I cannot use a portal, since I am looking for records in only one table." Ahhh, but you can Hannah 24! With a self-join. A self-join is a relationship linking a table back to itself. If you use a cartesian join (FMP 7) or a constant field (FMP 6 and earlier) you can display all records in the database in a portal on every record. Which I think is what you want to do. However it has its challenges. One can be speed: if all records in the file are related to each record, then browsing records can be slow since FMP needs to keep displaying a huge list of related records... even more so if the relationship or portal is set to sort the records. No problem with 10 or 100 records but it beging to be notices when the record count gets to 1,000. The second challenge is record locking in multi-user mode. FML locks the first row of the portal (related record) which can be a major interface bummer when there are more than one people browsing the file at once.
February 28, 200520 yr Author Thanks Vaughan! I created a self-join before, but noticed that it still displays only one record in the first row, and not all records across the specified range. Any way around that? H
February 28, 200520 yr If all your records are in a single table (FM7) or a single database (FM4-6) then you can create a self join portal. Quick Eg. three fields: First Name, Last Name, City If you use a portal with 'City' - 'City' as the portal relationship then use the other two Fields in the portal. This will display all the records who are located in the same city. Dont use the City field in the portal because it is not necessary. Swap the relationship to Last name - Last name and you will get all the users with the same last name.
February 28, 200520 yr Author Darren, Thank you very much! This completely solved my problem, for I previsouly assigned more than the crucial ID-ID self-join relationship.
Create an account or sign in to comment