You can use the following query structure:
select * from Carteira
inner join Movimento on Carteira.id = Movimento.carteira_id
inner join Ativo on Ativo.id = Movimento.ativo_id
NOTE: You have to be aware that if the Portfolio, Movement and Active tables have an attribute with the same name the (*) asterisk cannot be used in the query. Being necessary to qualify the names of the attributes you want to project in the query
Explaining the query
inner join Movimento on Carteira.id = Movimento.carteira_id
Sets the relationship attribute between the Movement and Portfolio tables to be the id attributes of the Portfolio and the Movement Portfolio Attribute
inner join Ativo on Ativo.id = Movimento.ativo_id
Sets the relationship attribute between the Movement and Active tables to be the id attributes of the Active table and the active attribute.
From what I understand the table Movement is a relationship entity. This way it is necessary to establish this structure to bring the relationship of Assets with Movements.
There are already many posts about this on the site, search for SQL and JOIN. Example: https://answall.com/q/6441, more links in the answer here, https://answall.com/q/267808 and much more.
– Bacco