select A.last_name from actor A
join film_actor FA on A.actor_id=FA.actor_id
join film F on FA.film_id=F.film_id
join inventory I on F.film_id=I.film_id
join rental R on I.inventory_id=R.inventory_id
left join customer C on R.customer_id=C.customer_id
group by A.last_name
;
show status like 'Last_query_cost';