1 Reply Latest reply on Oct 16, 2014 11:00 AM by philmodjunk

    Need to access last entry



      Need to access last entry


      We are entering scores for skills.  1 for not good, up to 5 for good.  Each score is being stored in a "Hitting Table"   I want to be able to present the last score entered for the player in the hitting table on my layout (list view).  I thought I could just enter the field "hitting::evalScoreHitting" and it would just present the last score, but it is presenting only the first score that was entered.  I am using a merge field to present it.  Any ideas why it uses the first entry and will not update on any later scores?

        • 1. Re: Need to access last entry

          When you place a field from a related table occurrence on your layout (as I am guessing is the case here) and do not put it in a portal, that field will automatically show data from the first related record--as you have discovered.

          A one row portal might be used where you specify a sort order that sorts the most recent related record to the top such as sorting on an auto-entered serial number field or timestamp field in descending order.

          You can also double click the relationship line linking your layout's table occurrence to this other related table occurrence to get a dialog where you can specify the same type of sort order as part of the relationship and then you can put the field directly on your layout without a portal as the sort specified in your relationship will make the "first related record" the one that was most recently created.