Well, it is a Loop [ though maybe someone knows better :-|
Set Variable [ $values_cnt; Value:ValueCount ( List ( Data::rpt_A ) ) ]
Set Variable [ $cnt; Value:$cnt + 1 ]
Exit Loop If [ $cnt > $values_cnt ]
Set Field [ Data::rpt_B[$cnt]; GetRepetition ( Data::rpt_A ; $cnt ) ]
Commit Records/Requests [ No dialog
P.S. The above script does not care whether "rpt_B" has any value; it overwrites it. The script could test for that, as it went; but it seemed you wanted to do this once, while it was empty. In either case, a test, of whichever method, might be a good idea.