12 Replies Latest reply on Dec 27, 2013 7:15 AM by philmodjunk

    Data Not Showing in the Portal

    TKnTexas

      Title

      Data Not Showing in the Portal

      Post

           For my DataBase I have a table to hold what I am calling configuration info, i.e. name, address, various data for value lists.  The global information is in one table.  The different value lists data is in separate tables, one table for each value lists.  Each table is linked by a common field, with the number 1.  It is an old technique for when I first started with Filemaker (v3). All of the tables are working, except one.  Because of the amount of data, I have scripted an import.  The import works. 

           But the data does not show in the portal on the CONFIG layout tab.  Not only does the imported data not show, but nothing shows, I can not even add manually.

      THill_ValueListIssue.png

        • 1. Re: Data Not Showing in the Portal
          philmodjunk

               I can't really see the details in your screen shot. When I zoom in, it's to blurry in many areas though I can see the data in the lower left corner and I can see that the match fields in both tables are named "LinkField". But what data type is the field? Is it text or number in the "config" table? Is it a calculation or data field?

          • 2. Re: Data Not Showing in the Portal
            TKnTexas

                 LinkField was defined as TEXT with DATA "1" and PROHIBIT MODIFICATION . . . 

                 Of the different tables for value lists I did, it was the last one.  After the others worked first time, I was surprised this didn't work.  As you can see, my import layout shows the LINKFIELD which is one of those options done on import.  I verify the "1" is there.  Knowing the "1" is in the single config record, as the others all display in their respective portals.

                  

            • 3. Re: Data Not Showing in the Portal
              philmodjunk

                   Yes, but what you see in the field could be misleading. What is the data type of the match field on the other side of the relationship? If it is also text, it's possible that a nonvisible character such as a space is in this field for one table and not the other. I'd use a number field for such a "1 field".

              • 4. Re: Data Not Showing in the Portal
                TKnTexas

                     All fields are TEXT.  I only use NUMBER when math will be done on a field.  All records in _Config_CoA have a "1" with no extra characters.  I have deleted it and re-created it making sure to follow the correct set up.  Creating PORTALS is something I am comfortable doing, having do them since FMI implemented PORTALS.  

                • 5. Re: Data Not Showing in the Portal
                  philmodjunk

                       I would still use a number field on both sides of the relationship for this and see what happens. If I am entering numbers in a field, I'd use a number data type. Not only does it avoid this possible issue, but if I need to sort on the field, it will sort like a number instead of text.

                       Did you re-enter the value for this field in all records of both tables?

                       You might also try re-indexing LinkField in the _config_CoA table. (any chance that indexing is turned off for it?)

                  • 6. Re: Data Not Showing in the Portal
                    TKnTexas

                         The confusion I have is that it is working in all of the other _Config_XXX tables that are set up the same way, actually set up from doing the first one and duplicating it  to create the others.  I will look to re-indexing.

                    • 7. Re: Data Not Showing in the Portal
                      TKnTexas

                           I want to let anyone else know, I got it fixed.  Some how I deleted the single record in the Main Config Table.  So there was no "1" to link to in the Chart of Accounts.  When I went back to look at the other value lists they were blank.  Restoring the record, all portals were populated.  

                           Now I just need to determine a way to not delete that record EVER.  :-)

                            

                           Phil, thank you for your assistance.

                      • 8. Re: Data Not Showing in the Portal
                        philmodjunk

                             I have a special report table in one of my systems. It needs to always have 12 records with a field numbered from 1 to 12. (It's a list view where each row of the view summarizes data for a different month of a specified year.)

                             Since I didn't want to have to remember to recreate those 12 records if I accidentally deleted a record during development or testing or after saving a clone of the file, I set up a script that checks the total number of records in the table and if there isn't exactly 12 records, the script deletes all records and creates new set of 12 records.

                             I think a modified version of that would work for you.

                        • 9. Re: Data Not Showing in the Portal
                          TKnTexas

                               Can you share that with me?  

                          • 10. Re: Data Not Showing in the Portal
                            philmodjunk

                                 It's pretty simple.

                                 ON Layout enter is used to perform this script

                                 If [ Get ( TotalRecordCount ) ≠ 12 ]
                                    Show All Records
                                    Delete All Records [No dialog]
                                    Loop
                                       Set Variable [$K ; value: $K + 1 ]
                                       Exit Loop if [ $K > 12 ]
                                       New Record/Request
                                       Set Field [Table::Month ; $K ]
                                    End Loop
                                 End IF

                                 In your case, this could be simplified to:

                                 If [ Not Get ( TotalRecordCount ) ]
                                    New Record/Request
                                 End If

                            • 11. Re: Data Not Showing in the Portal
                              TKnTexas

                                   Thanks a bunch.  The record should not get deleted.  One a company does the set up, there is not reason to go back to the layout, or a rare to do so.

                                    

                              • 12. Re: Data Not Showing in the Portal
                                philmodjunk

                                     Yes, assuming that you don't have a "delete" option lurking somewhere in your relationship graph that shouldn't be there, this is mainly a method for making sure that any saved clones of your file will automatically update to add the missing record(s) so that you don't have to remember to do so. This comes up when you are restoring a damaged database or upgrading to a new version of your system by importing data from old into new...