Duplicating a portal row/record in Filemaker

Posted on 2010-01-07
Last Modified: 2012-05-08
I want a script that takes me to a portal row and then duplicates the portal row. The navigation part of the script which takes me to the selected row works fine. With the cursor blinking at me in the correct row, on implementing Duplicate Record from the menu (to test the action), all records disappear from view in the portal and all other portals on the tab control go blank as well. The cursor ends up on the main record.

Having selected the portal row I cannot understand why this should happen. Can anyone advise me as to why this should happen and not simply reproduce the record?

Incidentally, no duplicate record shows up in the underlying table.  
Question by:c0link
    LVL 10

    Accepted Solution

    When you duplicate like this, you are duplicating the RECORD LINKING TO THE PORTAL, not the record in the portal row itself. When you dupe the record, for some reason the relationship key for all the portals is lost.

    You are almost there though.

    Just do a freeze window, go to related record(show in the appropriate layout for the child table), duplicate record, then return to original layout. Your new record should appear in the portal.
    Finally, you might have to go to portal row last or first...not sure how you sort.
    There are other ways, but thats probably the simplest.
    LVL 28

    Expert Comment

    duplicating a record duplicates the current record of the current table on which the current layout is based, even if you are currently selecting a portal row.

    to duplicate a related record, there are several ways, the simplest is:
    (from the portal raw)
    goto related record, using the related table layout
    duplicate record
    goto layout (original)

    Author Closing Comment

    Simple is very good.
    Now I know the flow it works well. Also explains why the blanks. It was because by trying to duplicate the linked record it could not recreate a unique value field, hence it blanked.

    Freeze window is another useful tip to remember.

    Thanks a lot.

    Author Comment

    Received this after another solution (same) presented. Understanding what was actually being duplicated explained everything.

    Thanks for your feedback.
    LVL 28

    Expert Comment

    I had not seen the 1st solution, it's been posted while I was typing mine... EE needs ajax!
    just a remark about: "for some reason the relationship key for all the portals is lost."
    makes sense, when you duplicate the current record, the ID is changed, so related records are not the same for the dupped record.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Enabling OSINT in Activity Based Intelligence

    Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

    Problem: You have a hosted FileMaker database and users are tired of having to use Open Remote or Open Recent to access the database. They say, "can't you just give us something to double-click on rather than have to go through those dialogs?" An…
    Having just upgraded from Filemaker 11 to Filemaker 12 over the weekend, we thought we would add some tips for others making the same move.  In general, our installation went without incident. Please note that this is not a replacement for Chapter 5…
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now