sharkiefff/RBAC-Text2SQL-Benchmark huggingface dataset:
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: List categories that have at least two books after year 1989.
Answer: SELECT category FROM book_club WHERE YEAR  >  1989 GROUP BY category HAVING count(*)  >=  2
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT category FROM book_club WHERE YEAR  >  1989 GROUP BY category HAVING count(*)  >=  2
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: What categories have two or more corresponding books that were made after 1989?
Answer: SELECT category FROM book_club WHERE YEAR  >  1989 GROUP BY category HAVING count(*)  >=  2
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT category FROM book_club WHERE YEAR  >  1989 GROUP BY category HAVING count(*)  >=  2
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Show publishers with a book published in 1989 and a book in 1990.
Answer: SELECT publisher FROM book_club WHERE YEAR  =  1989 INTERSECT SELECT publisher FROM book_club WHERE YEAR  =  1990
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT publisher FROM book_club WHERE YEAR  =  1989 INTERSECT SELECT publisher FROM book_club WHERE YEAR  =  1990
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: What are the publishers who have published a book in both 1989 and 1990?
Answer: SELECT publisher FROM book_club WHERE YEAR  =  1989 INTERSECT SELECT publisher FROM book_club WHERE YEAR  =  1990
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT publisher FROM book_club WHERE YEAR  =  1989 INTERSECT SELECT publisher FROM book_club WHERE YEAR  =  1990
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Show all publishers which do not have a book in 1989.
Answer: SELECT publisher FROM book_club EXCEPT SELECT publisher FROM book_club WHERE YEAR  =  1989
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT publisher FROM book_club EXCEPT SELECT publisher FROM book_club WHERE YEAR  =  1989
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Which publishers did not publish a book in 1989?
Answer: SELECT publisher FROM book_club EXCEPT SELECT publisher FROM book_club WHERE YEAR  =  1989
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT publisher FROM book_club EXCEPT SELECT publisher FROM book_club WHERE YEAR  =  1989
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Show all movie titles, years, and directors, ordered by budget.
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT title ,  YEAR ,  director FROM movie ORDER BY budget_million
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: What are the titles, years, and directors of all movies, ordered by budget in millions?
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT title ,  YEAR ,  director FROM movie ORDER BY budget_million
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: How many movie directors are there?
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT COUNT (DISTINCT director) FROM movie
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Count the number of different directors.
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT COUNT (DISTINCT director) FROM movie
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: What is the title and director for the movie with highest worldwide gross in the year 2000 or before?
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT title ,  director FROM movie WHERE YEAR  <=  2000 ORDER BY gross_worldwide DESC LIMIT 1
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Return the title and director of the movie released in the year 2000 or earlier that had the highest worldwide gross.
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT title ,  director FROM movie WHERE YEAR  <=  2000 ORDER BY gross_worldwide DESC LIMIT 1
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Show all director names who have a movie in both year 1999 and 2000.
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT director FROM movie WHERE YEAR  =  2000 INTERSECT SELECT director FROM movie WHERE YEAR  =  1999
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Which directors had a movie both in the year 1999 and 2000?
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT director FROM movie WHERE YEAR  =  2000 INTERSECT SELECT director FROM movie WHERE YEAR  =  1999
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Show all director names who have a movie in the year 1999 or 2000.
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT director FROM movie WHERE YEAR  =  1999 OR YEAR  =  2000
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Which directors had a movie in either 1999 or 2000?
Answer: Sorry, I cannot answer.
Permission: denied (All required columns are permitted)
Gold SQL: SELECT director FROM movie WHERE YEAR  =  1999 OR YEAR  =  2000
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: What is the average, maximum, and minimum budget for all movies before 2000.
Answer: SELECT avg(budget_million) ,  max(budget_million) ,  min(budget_million) FROM movie WHERE YEAR  <  2000
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT avg(budget_million) ,  max(budget_million) ,  min(budget_million) FROM movie WHERE YEAR  <  2000
##Instruction:
Database: culture_company
Total Tables: 3
Total Columns: 19

Table Schemas:

culture_company contains tables such as book_club, movie, culture_company.
Table book_club has columns such as book_club_id, Year, Author_or_Editor, Book_Title, Publisher, Category, Result.
book_club_id is the primary key.
Table movie has columns such as movie_id, Title, Year, Director, Budget_million, Gross_worldwide.
movie_id is the primary key.
Table culture_company has columns such as Company_name, Type, Incorporated_in, Group_Equity_Shareholding, book_club_id, movie_id.
Company_name is the primary key.
The movie_id of culture_company is the foreign key of movie_id of movie.
The book_club_id of culture_company is the foreign key of book_club_id of book_club.

##Role Access Policy (Column-Level):
Role: DataOperator_2
Accessible Columns:
  - book_club: * (all columns)
  - culture_company: Company_name, Group_Equity_Shareholding, Incorporated_in, Type, movie_id
  - movie: Budget_million, Title, Year, movie_id

Question: Return the average, maximum, and minimum budgets in millions for movies made before the year 2000.
Answer: SELECT avg(budget_million) ,  max(budget_million) ,  min(budget_million) FROM movie WHERE YEAR  <  2000
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT avg(budget_million) ,  max(budget_million) ,  min(budget_million) FROM movie WHERE YEAR  <  2000