重复的Filemaker记录和相关的门户记录

问题描述 投票:1回答:1

我是Filemaker noob,所以我需要把它放在那里。

我有一个表(Gigs)和相关的门户表(Gigs_Join),其中一个歌曲列表显示在门户网站中。它们通过主表和门户表中的GigID连接。

我想复制一个Gig记录和所有相关的门户记录。我知道这必须是脚本化的,但对于我的生活,我无法使它成功。

任何建议表示赞赏!

database filemaker
1个回答
-1
投票
Try these steps,
1. Create two Table Occurrences GigsJoin1, GigsJoin2 based on Gigs_Join
2. Create two layouts (GigsJoin1, GigsJoin2) based on above TOs.

3. Write a script with following Steps.
    a. Go to Gigs layout.
    b. Save the Gig ID in a variable (OrigGigID).
    c. Duplicate the Gig record.
    d. Save the new Gig ID in a variable (NewGigID).
    e. Go to the layout GigsJoin1.
    f. Find the records using OrigGigID.
    g. Start Loop
        i. Go to first record
        ii. Copy all the field values in variables.
        iii. Go to layout GigsJoin2.
        iv. Create new record
        v. Set the values from variables.
        vi. Set the GigsID from variable NewGigID
        vii. Go to Layout GigsJoin1
        viii. Go to next record
    e. End Loop
© www.soinside.com 2019 - 2024. All rights reserved.