I guess the easiest way to do this is the following. First to understand what i mean dorp an expression box to into you reapeating table, click the fx button, select insert formula and put postion() as the formula. like this you will see that everytime you add a new section the counter gets incremented. Now put a text box control into your repeating section and as a value set the value of the previous selected id from the dorp down list. only thing left to do is to have a conditional formatting on your dropdownlist to hide it once the counter of the repeating section is higher than 1 (i guess you don´t need the ddl anymore if the id has to be the same anyway)
hope this helps