Populate table with query from another table

Hello, I know the theory behind populating a table by doing a query from another table, but can’t figure it out for this particular case, maybe someone who has slept more hours than me can give me a hand :smiley:

I have this query:

select dvdpedia.id, title, studio.id as foundStudioId, studio
from dvdpedia 
LEFT OUTER JOIN studio2title ON studio2title.titleId = dvdpedia.id
JOIN studio ON studio.id = studio2title.pId

Which produces something like:

±----±------------------------------------------±--------------±----------------------+
| id | title | foundStudioId | studio |
±----±------------------------------------------±--------------±----------------------+
| 16 | Harry Potter and the Prisoner of Azkaban | 1 | Warner Bros. Pictures |
| 23 | The Dark Knight | 1 | Warner Bros. Pictures |
| 27 | Harry Potter and the Goblet of Fire | 1 | Warner Bros. Pictures |
| 28 | Harry Potter and the Half-Blood Prince | 1 | Warner Bros. Pictures |

Now I need to put foundStudioId into dvdpedia.studioId for each corresponding row. But can’t really figure out how to do it so that it ends up in the right entry.

Many thanks.