-- Database schema
| Episode : episode_id [ TEXT ] primary_key , season [ INTEGER ] , episode [ INTEGER ] , number_in_series [ INTEGER ] , title [ TEXT ] , summary [ TEXT ] , air_date [ TEXT ] , episode_image [ TEXT ] , rating [ REAL ] , votes [ INTEGER ] | Person : name [ TEXT ] primary_key , birthdate [ TEXT ] , birth_name [ TEXT ] , birth_place [ TEXT ] , birth_region [ TEXT ] , birth_country [ TEXT ] , height_meters [ REAL ] , nickname [ TEXT ] | Award : award_id [ INTEGER ] primary_key , organization [ TEXT ] , year [ INTEGER ] , award_category [ TEXT ] , award [ TEXT ] , person [ TEXT ] Award.person = Person.name , role [ TEXT ] , episode_id [ TEXT ] Award.episode_id = Episode.episode_id , season [ TEXT ] , song [ TEXT ] , result [ TEXT ] | Character_Award : award_id [ INTEGER ] Character_Award.award_id = Award.award_id , character [ TEXT ] | Credit : episode_id [ TEXT ] Credit.episode_id = Episode.episode_id , category [ TEXT ] , person [ TEXT ] Credit.person = Person.name , role [ TEXT ] , credited [ TEXT ] | Keyword : episode_id [ TEXT ] Keyword.episode_id = Episode.episode_id , keyword [ TEXT ] | Vote : episode_id [ TEXT ] Vote.episode_id = Episode.episode_id , stars [ INTEGER ] , votes [ INTEGER ] , percent [ REAL ] |
-- -- Based on the credits, state how many roles were played in the 5th episode of simpson 20.

SELECT COUNT(DISTINCT T2.role) FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id WHERE T1.episode = 5;