actor_info
Documentation | Sakila |
Name | actor_info |
Module | Views |
The actor_info view provides a list of all actors, including the films in which they have performed, broken down by category.
The staff_list view incorporates data from the film, actor, category, film_actor, and film_category tables.
Columns
Key | Name | Data type | Null | Attributes | References | Description | ||
---|---|---|---|---|---|---|---|---|
1 | actor_id | unsigned smallint(5, 0) | Default: 0 | The actor ID. | ||||
The actor ID. Default: 0 |
||||||||
2 | first_name | varchar(45) | The actor's first name. | |||||
The actor's first name. |
||||||||
3 | last_name | varchar(45) | The actor's last name. | |||||
The actor's last name. |
||||||||
4 | film_info | text | Information about film - name and title. | |||||
Information about film - name and title. |
Script
select `a`.`actor_id` AS `actor_id`,`a`.`first_name` AS `first_name`,`a`.`last_name` AS `last_name`,group_concat(distinct concat(`c`.`name`,': ',(select group_concat(`f`.`title` order by `f`.`title` ASC separator ', ') from ((`sakila`.`film` `f` join `sakila`.`film_category` `fc` on((`f`.`film_id` = `fc`.`film_id`))) join `sakila`.`film_actor` `fa` on((`f`.`film_id` = `fa`.`film_id`))) where ((`fc`.`category_id` = `c`.`category_id`) and (`fa`.`actor_id` = `a`.`actor_id`)))) order by `c`.`name` ASC separator '; ') AS `film_info` from (((`sakila`.`actor` `a` left join `sakila`.`film_actor` `fa` on((`a`.`actor_id` = `fa`.`actor_id`))) left join `sakila`.`film_category` `fc` on((`fa`.`film_id` = `fc`.`film_id`))) left join `sakila`.`category` `c` on((`fc`.`category_id` = `c`.`category_id`))) group by `a`.`actor_id`,`a`.`first_name`,`a`.`last_name` |
Exported: 2018-10-12 17:43, Last imported: 2018-08-06 10:44