sert121/SpiderSQL huggingface dataset:
-- Language PostgreSQL
        -- Tables: 
             -- Table: book club 
columns : [['book club id', 'number'], ['year', 'number'], ['author or editor', 'text'], ['book title', 'text'], ['publisher', 'text'], ['category', 'text'], ['result', 'text']]

 -- Table: movie 
columns : [['movie id', 'number'], ['title', 'text'], ['year', 'number'], ['director', 'text'], ['budget million', 'number'], ['gross worldwide', 'number']]

 -- Table: culture company 
columns : [['company name', 'text'], ['type', 'text'], ['incorporated in', 'text'], ['group equity shareholding', 'number'], ['book club id', 'text'], ['movie id', 'text']]

You are a SQL code translator. You have been given the Table data above. Your role is to translate natural language to PostgreSQL. 
You should not select columns that are not part of the tables provided to you. Think step by step.
Your only output should be SQL code. Do not include any other text. Only SQL code.



Question: List all company names with a book published by Alyson.
SQL: SELECT T1.company_name FROM culture_company AS T1 JOIN book_club AS T2 ON T1.book_club_id  =  T2.book_club_id WHERE T2.publisher  =  'Alyson'
-- Language PostgreSQL
        -- Tables: 
             -- Table: book club 
columns : [['book club id', 'number'], ['year', 'number'], ['author or editor', 'text'], ['book title', 'text'], ['publisher', 'text'], ['category', 'text'], ['result', 'text']]

 -- Table: movie 
columns : [['movie id', 'number'], ['title', 'text'], ['year', 'number'], ['director', 'text'], ['budget million', 'number'], ['gross worldwide', 'number']]

 -- Table: culture company 
columns : [['company name', 'text'], ['type', 'text'], ['incorporated in', 'text'], ['group equity shareholding', 'number'], ['book club id', 'text'], ['movie id', 'text']]

You are a SQL code translator. You have been given the Table data above. Your role is to translate natural language to PostgreSQL. 
You should not select columns that are not part of the tables provided to you. Think step by step.
Your only output should be SQL code. Do not include any other text. Only SQL code.



Question: What are all the company names that have a book published by Alyson?
SQL: SELECT T1.company_name FROM culture_company AS T1 JOIN book_club AS T2 ON T1.book_club_id  =  T2.book_club_id WHERE T2.publisher  =  'Alyson'
-- Language PostgreSQL
        -- Tables: 
             -- Table: book club 
columns : [['book club id', 'number'], ['year', 'number'], ['author or editor', 'text'], ['book title', 'text'], ['publisher', 'text'], ['category', 'text'], ['result', 'text']]

 -- Table: movie 
columns : [['movie id', 'number'], ['title', 'text'], ['year', 'number'], ['director', 'text'], ['budget million', 'number'], ['gross worldwide', 'number']]

 -- Table: culture company 
columns : [['company name', 'text'], ['type', 'text'], ['incorporated in', 'text'], ['group equity shareholding', 'number'], ['book club id', 'text'], ['movie id', 'text']]

You are a SQL code translator. You have been given the Table data above. Your role is to translate natural language to PostgreSQL. 
You should not select columns that are not part of the tables provided to you. Think step by step.
Your only output should be SQL code. Do not include any other text. Only SQL code.



Question: Show the movie titles and book titles for all companies in China.
SQL: SELECT T1.title ,  T3.book_title FROM movie AS T1 JOIN culture_company AS T2 ON T1.movie_id  =  T2.movie_id JOIN book_club AS T3 ON T3.book_club_id  =  T2.book_club_id WHERE T2.incorporated_in  =  'China'
-- Language PostgreSQL
        -- Tables: 
             -- Table: book club 
columns : [['book club id', 'number'], ['year', 'number'], ['author or editor', 'text'], ['book title', 'text'], ['publisher', 'text'], ['category', 'text'], ['result', 'text']]

 -- Table: movie 
columns : [['movie id', 'number'], ['title', 'text'], ['year', 'number'], ['director', 'text'], ['budget million', 'number'], ['gross worldwide', 'number']]

 -- Table: culture company 
columns : [['company name', 'text'], ['type', 'text'], ['incorporated in', 'text'], ['group equity shareholding', 'number'], ['book club id', 'text'], ['movie id', 'text']]

You are a SQL code translator. You have been given the Table data above. Your role is to translate natural language to PostgreSQL. 
You should not select columns that are not part of the tables provided to you. Think step by step.
Your only output should be SQL code. Do not include any other text. Only SQL code.



Question: What are the titles of movies and books corresponding to companies incorporated in China?
SQL: SELECT T1.title ,  T3.book_title FROM movie AS T1 JOIN culture_company AS T2 ON T1.movie_id  =  T2.movie_id JOIN book_club AS T3 ON T3.book_club_id  =  T2.book_club_id WHERE T2.incorporated_in  =  'China'
-- Language PostgreSQL
        -- Tables: 
             -- Table: book club 
columns : [['book club id', 'number'], ['year', 'number'], ['author or editor', 'text'], ['book title', 'text'], ['publisher', 'text'], ['category', 'text'], ['result', 'text']]

 -- Table: movie 
columns : [['movie id', 'number'], ['title', 'text'], ['year', 'number'], ['director', 'text'], ['budget million', 'number'], ['gross worldwide', 'number']]

 -- Table: culture company 
columns : [['company name', 'text'], ['type', 'text'], ['incorporated in', 'text'], ['group equity shareholding', 'number'], ['book club id', 'text'], ['movie id', 'text']]

You are a SQL code translator. You have been given the Table data above. Your role is to translate natural language to PostgreSQL. 
You should not select columns that are not part of the tables provided to you. Think step by step.
Your only output should be SQL code. Do not include any other text. Only SQL code.



Question: Show all company names with a movie directed in year 1999.
SQL: SELECT T2.company_name FROM movie AS T1 JOIN culture_company AS T2 ON T1.movie_id  =  T2.movie_id WHERE T1.year  =  1999
-- Language PostgreSQL
        -- Tables: 
             -- Table: book club 
columns : [['book club id', 'number'], ['year', 'number'], ['author or editor', 'text'], ['book title', 'text'], ['publisher', 'text'], ['category', 'text'], ['result', 'text']]

 -- Table: movie 
columns : [['movie id', 'number'], ['title', 'text'], ['year', 'number'], ['director', 'text'], ['budget million', 'number'], ['gross worldwide', 'number']]

 -- Table: culture company 
columns : [['company name', 'text'], ['type', 'text'], ['incorporated in', 'text'], ['group equity shareholding', 'number'], ['book club id', 'text'], ['movie id', 'text']]

You are a SQL code translator. You have been given the Table data above. Your role is to translate natural language to PostgreSQL. 
You should not select columns that are not part of the tables provided to you. Think step by step.
Your only output should be SQL code. Do not include any other text. Only SQL code.



Question: What are all company names that have a corresponding movie directed in the year 1999?
SQL: SELECT T2.company_name FROM movie AS T1 JOIN culture_company AS T2 ON T1.movie_id  =  T2.movie_id WHERE T1.year  =  1999