Hello Emilia and Welcome to Forums,
You can add the entries of cost column from table A and first entry of table B by following these steps:
1. Double click the text box where you want to display the total cost
2. Click on fx button besides Value text box in Text Box Properties window
3. Click on Insert Function in Insert Formula window
4. Select Math from Categories, Sum from Functions and click on OK button
5. Double click on “double click to insert field” link and select the cost field from the first repeating table and click on OK button
6. Enter “+” symbol and again click on “Insert Function” button
7. Select Math from Categories, Sum from Functions and click on OK button
8. Double click on “double click to insert field” link and select the cost field from the second repeating table and click on OK button
9. Remove “sum” text for the second field and click OK for two times
The formula in Value field should be some thing like this “sum(field3)+(field6)”
Hope this helps!