Unnamed: 0
int64
0
78.6k
answer
stringlengths
18
557
question
stringlengths
12
244
context
stringlengths
27
489
translated_answer
stringlengths
12
992
2,600
SELECT document_name FROM documents WHERE NOT document_code IN (SELECT document_code FROM document_sections)
Find all the name of documents without any sections.
CREATE TABLE document_sections (document_name VARCHAR, document_code VARCHAR); CREATE TABLE documents (document_name VARCHAR, document_code VARCHAR)
Encontre todos os nomes dos documentos sem nenhuma seção.
2,601
SELECT user_name, password FROM users GROUP BY role_code ORDER BY COUNT(*) DESC LIMIT 1
List all the username and passwords of users with the most popular role.
CREATE TABLE users (user_name VARCHAR, password VARCHAR, role_code VARCHAR)
Liste todos os nomes de usuário e senhas dos usuários com a função mais popular.
2,602
SELECT AVG(t1.access_count) FROM documents AS t1 JOIN document_functional_areas AS t2 ON t1.document_code = t2.document_code JOIN functional_areas AS t3 ON t2.functional_area_code = t3.functional_area_code WHERE t3.functional_area_description = "Acknowledgement"
Find the average access counts of documents with functional area "Acknowledgement".
CREATE TABLE document_functional_areas (document_code VARCHAR, functional_area_code VARCHAR); CREATE TABLE documents (access_count INTEGER, document_code VARCHAR); CREATE TABLE functional_areas (functional_area_code VARCHAR, functional_area_description VARCHAR)
Encontre as contagens médias de acesso de documentos com área funcional "Reconhecimento".
2,603
SELECT document_name FROM documents EXCEPT SELECT t1.document_name FROM documents AS t1 JOIN document_sections AS t2 ON t1.document_code = t2.document_code JOIN document_sections_images AS t3 ON t2.section_id = t3.section_id
Find names of the document without any images.
CREATE TABLE document_sections_images (section_id VARCHAR); CREATE TABLE documents (document_name VARCHAR); CREATE TABLE documents (document_name VARCHAR, document_code VARCHAR); CREATE TABLE document_sections (document_code VARCHAR, section_id VARCHAR)
Encontre os nomes do documento sem imagens.
2,604
SELECT t1.document_name FROM documents AS t1 JOIN document_sections AS t2 ON t1.document_code = t2.document_code GROUP BY t1.document_code ORDER BY COUNT(*) DESC LIMIT 1
What is the name of the document with the most number of sections?
CREATE TABLE document_sections (document_code VARCHAR); CREATE TABLE documents (document_name VARCHAR, document_code VARCHAR)
Qual é o nome do documento com o maior número de seções?
2,605
SELECT document_name FROM documents WHERE document_name LIKE "%CV%"
List all the document names which contains "CV".
CREATE TABLE documents (document_name VARCHAR)
Listar todos os nomes dos documentos que contém "CV".
2,606
SELECT COUNT(*) FROM users WHERE user_login = 1
How many users are logged in?
CREATE TABLE users (user_login VARCHAR)
Quantos usuários estão logados?
2,607
SELECT role_description FROM ROLES WHERE role_code = (SELECT role_code FROM users WHERE user_login = 1 GROUP BY role_code ORDER BY COUNT(*) DESC LIMIT 1)
Find the description of the most popular role among the users that have logged in.
CREATE TABLE users (role_description VARCHAR, role_code VARCHAR, user_login VARCHAR); CREATE TABLE ROLES (role_description VARCHAR, role_code VARCHAR, user_login VARCHAR)
Encontre a descrição da função mais popular entre os usuários que fizeram login.
2,608
SELECT AVG(access_count) FROM documents GROUP BY document_structure_code ORDER BY COUNT(*) LIMIT 1
Find the average access count of documents with the least popular structure.
CREATE TABLE documents (access_count INTEGER, document_structure_code VARCHAR)
Encontre a contagem média de acesso de documentos com a estrutura menos popular.
2,609
SELECT image_name, image_url FROM images ORDER BY image_name
List all the image name and URLs in the order of their names.
CREATE TABLE images (image_name VARCHAR, image_url VARCHAR)
Listar todos os nomes de imagem e URLs na ordem de seus nomes.
2,610
SELECT COUNT(*), role_code FROM users GROUP BY role_code
Find the number of users in each role.
CREATE TABLE users (role_code VARCHAR)
Encontre o número de usuários em cada função.
2,611
SELECT document_type_code FROM documents GROUP BY document_type_code HAVING COUNT(*) > 2
What document types have more than 2 corresponding documents?
CREATE TABLE documents (document_type_code VARCHAR)
Quais tipos de documentos têm mais de 2 documentos correspondentes?
2,612
SELECT COUNT(*) FROM Companies
How many companies are there?
CREATE TABLE Companies (Id VARCHAR)
Quantas empresas existem?
2,613
SELECT name FROM Companies ORDER BY Market_Value_billion DESC
List the names of companies in descending order of market value.
CREATE TABLE Companies (name VARCHAR, Market_Value_billion VARCHAR)
Listar os nomes das empresas em ordem decrescente de valor de mercado.
2,614
SELECT name FROM Companies WHERE Headquarters <> 'USA'
What are the names of companies whose headquarters are not "USA"?
CREATE TABLE Companies (name VARCHAR, Headquarters VARCHAR)
Quais são os nomes das empresas cuja sede não é "EUA"?
2,615
SELECT name, Assets_billion FROM Companies ORDER BY name
What are the name and assets of each company, sorted in ascending order of company name?
CREATE TABLE Companies (name VARCHAR, Assets_billion VARCHAR)
Quais são o nome e os ativos de cada empresa, classificados em ordem crescente de nome da empresa?
2,616
SELECT AVG(Profits_billion) FROM Companies
What are the average profits of companies?
CREATE TABLE Companies (Profits_billion INTEGER)
Quais são os lucros médios das empresas?
2,617
SELECT MAX(Sales_billion), MIN(Sales_billion) FROM Companies WHERE Industry <> "Banking"
What are the maximum and minimum sales of the companies whose industries are not "Banking".
CREATE TABLE Companies (Sales_billion INTEGER, Industry VARCHAR)
Quais são as vendas máximas e mínimas das empresas cujas indústrias não são "Banking".
2,618
SELECT COUNT(DISTINCT Industry) FROM Companies
How many different industries are the companies in?
CREATE TABLE Companies (Industry VARCHAR)
Em quantas indústrias diferentes estão as empresas?
2,619
SELECT name FROM buildings ORDER BY Height DESC
List the names of buildings in descending order of building height.
CREATE TABLE buildings (name VARCHAR, Height VARCHAR)
Listar os nomes dos edifícios em ordem decrescente de altura do edifício.
2,620
SELECT Stories FROM buildings ORDER BY Height DESC LIMIT 1
Find the stories of the building with the largest height.
CREATE TABLE buildings (Stories VARCHAR, Height VARCHAR)
Encontre as histórias do edifício com a maior altura.
2,621
SELECT T3.name, T2.name FROM Office_locations AS T1 JOIN buildings AS T2 ON T1.building_id = T2.id JOIN Companies AS T3 ON T1.company_id = T3.id
List the name of a building along with the name of a company whose office is in the building.
CREATE TABLE buildings (name VARCHAR, id VARCHAR); CREATE TABLE Office_locations (building_id VARCHAR, company_id VARCHAR); CREATE TABLE Companies (name VARCHAR, id VARCHAR)
Liste o nome de um edifício juntamente com o nome de uma empresa cujo escritório está no edifício.
2,622
SELECT T2.name FROM Office_locations AS T1 JOIN buildings AS T2 ON T1.building_id = T2.id JOIN Companies AS T3 ON T1.company_id = T3.id GROUP BY T1.building_id HAVING COUNT(*) > 1
Show the names of the buildings that have more than one company offices.
CREATE TABLE buildings (name VARCHAR, id VARCHAR); CREATE TABLE Companies (id VARCHAR); CREATE TABLE Office_locations (building_id VARCHAR, company_id VARCHAR)
Mostre os nomes dos edifícios que têm mais de um escritório da empresa.
2,623
SELECT T2.name FROM Office_locations AS T1 JOIN buildings AS T2 ON T1.building_id = T2.id JOIN Companies AS T3 ON T1.company_id = T3.id GROUP BY T1.building_id ORDER BY COUNT(*) DESC LIMIT 1
Show the name of the building that has the most company offices.
CREATE TABLE buildings (name VARCHAR, id VARCHAR); CREATE TABLE Companies (id VARCHAR); CREATE TABLE Office_locations (building_id VARCHAR, company_id VARCHAR)
Mostre o nome do edifício que tem mais escritórios da empresa.
2,624
SELECT name FROM buildings WHERE Status = "on-hold" ORDER BY Stories
Please show the names of the buildings whose status is "on-hold", in ascending order of stories.
CREATE TABLE buildings (name VARCHAR, Status VARCHAR, Stories VARCHAR)
Por favor, mostre os nomes dos edifícios cujo status é "on-hold", em ordem crescente de histórias.
2,625
SELECT Industry, COUNT(*) FROM Companies GROUP BY Industry
Please show each industry and the corresponding number of companies in that industry.
CREATE TABLE Companies (Industry VARCHAR)
Por favor, mostre cada setor e o número correspondente de empresas nesse setor.
2,626
SELECT Industry FROM Companies GROUP BY Industry ORDER BY COUNT(*) DESC
Please show the industries of companies in descending order of the number of companies.
CREATE TABLE Companies (Industry VARCHAR)
Por favor, mostre as indústrias das empresas em ordem decrescente do número de empresas.
2,627
SELECT Industry FROM Companies GROUP BY Industry ORDER BY COUNT(*) DESC LIMIT 1
List the industry shared by the most companies.
CREATE TABLE Companies (Industry VARCHAR)
Liste a indústria compartilhada pela maioria das empresas.
2,628
SELECT name FROM buildings WHERE NOT id IN (SELECT building_id FROM Office_locations)
List the names of buildings that have no company office.
CREATE TABLE buildings (name VARCHAR, id VARCHAR, building_id VARCHAR); CREATE TABLE Office_locations (name VARCHAR, id VARCHAR, building_id VARCHAR)
Listar os nomes dos edifícios que não têm escritório da empresa.
2,629
SELECT Industry FROM Companies WHERE Headquarters = "USA" INTERSECT SELECT Industry FROM Companies WHERE Headquarters = "China"
Show the industries shared by companies whose headquarters are "USA" and companies whose headquarters are "China".
CREATE TABLE Companies (Industry VARCHAR, Headquarters VARCHAR)
Mostre as indústrias compartilhadas por empresas cuja sede é "EUA" e empresas cuja sede é "China".
2,630
SELECT COUNT(*) FROM Companies WHERE Industry = "Banking" OR Industry = "Conglomerate"
Find the number of companies whose industry is "Banking" or "Conglomerate",
CREATE TABLE Companies (Industry VARCHAR)
Encontre o número de empresas cuja indústria é "Banco" ou "Conglomerado",
2,631
SELECT Headquarters FROM Companies GROUP BY Headquarters HAVING COUNT(*) > 2
Show the headquarters shared by more than two companies.
CREATE TABLE Companies (Headquarters VARCHAR)
Mostre a sede compartilhada por mais de duas empresas.
2,632
SELECT COUNT(*) FROM Products
How many products are there?
CREATE TABLE Products (Id VARCHAR)
Quantos produtos existem?
2,633
SELECT Product_Name FROM Products ORDER BY Product_Price
List the name of products in ascending order of price.
CREATE TABLE Products (Product_Name VARCHAR, Product_Price VARCHAR)
Listar o nome dos produtos em ordem crescente de preço.
2,634
SELECT Product_Name, Product_Type_Code FROM Products
What are the names and type codes of products?
CREATE TABLE Products (Product_Name VARCHAR, Product_Type_Code VARCHAR)
Quais são os nomes e códigos de tipo de produtos?
2,635
SELECT Product_Price FROM Products WHERE Product_Name = "Dining" OR Product_Name = "Trading Policy"
Show the prices of the products named "Dining" or "Trading Policy".
CREATE TABLE Products (Product_Price VARCHAR, Product_Name VARCHAR)
Mostrar os preços dos produtos denominados "Dining" ou "Trading Policy".
2,636
SELECT AVG(Product_Price) FROM Products
What is the average price for products?
CREATE TABLE Products (Product_Price INTEGER)
Qual é o preço médio dos produtos?
2,637
SELECT Product_Name FROM Products ORDER BY Product_Price DESC LIMIT 1
What is the name of the product with the highest price?
CREATE TABLE Products (Product_Name VARCHAR, Product_Price VARCHAR)
Qual é o nome do produto com o preço mais alto?
2,638
SELECT Product_Type_Code, COUNT(*) FROM Products GROUP BY Product_Type_Code
Show different type codes of products and the number of products with each type code.
CREATE TABLE Products (Product_Type_Code VARCHAR)
Mostrar diferentes códigos de tipo de produtos e o número de produtos com cada código de tipo.
2,639
SELECT Product_Type_Code FROM Products GROUP BY Product_Type_Code ORDER BY COUNT(*) DESC LIMIT 1
Show the most common type code across products.
CREATE TABLE Products (Product_Type_Code VARCHAR)
Mostre o código de tipo mais comum em todos os produtos.
2,640
SELECT Product_Type_Code FROM Products GROUP BY Product_Type_Code HAVING COUNT(*) >= 2
Show the product type codes that have at least two products.
CREATE TABLE Products (Product_Type_Code VARCHAR)
Mostre os códigos do tipo de produto que têm pelo menos dois produtos.
2,641
SELECT Product_Type_Code FROM Products WHERE Product_Price > 4500 INTERSECT SELECT Product_Type_Code FROM Products WHERE Product_Price < 3000
Show the product type codes that have both products with price higher than 4500 and products with price lower than 3000.
CREATE TABLE Products (Product_Type_Code VARCHAR, Product_Price INTEGER)
Mostrar os códigos de tipo de produto que têm ambos os produtos com preço superior a 4500 e produtos com preço inferior a 3000.
2,642
SELECT T1.Product_Name, COUNT(*) FROM Products AS T1 JOIN Products_in_Events AS T2 ON T1.Product_ID = T2.Product_ID GROUP BY T1.Product_Name
Show the names of products and the number of events they are in.
CREATE TABLE Products (Product_Name VARCHAR, Product_ID VARCHAR); CREATE TABLE Products_in_Events (Product_ID VARCHAR)
Mostre os nomes dos produtos e o número de eventos em que eles estão.
2,643
SELECT T1.Product_Name, COUNT(*) FROM Products AS T1 JOIN Products_in_Events AS T2 ON T1.Product_ID = T2.Product_ID GROUP BY T1.Product_Name ORDER BY COUNT(*) DESC
Show the names of products and the number of events they are in, sorted by the number of events in descending order.
CREATE TABLE Products (Product_Name VARCHAR, Product_ID VARCHAR); CREATE TABLE Products_in_Events (Product_ID VARCHAR)
Mostre os nomes dos produtos e o número de eventos em que eles estão, classificados pelo número de eventos em ordem decrescente.
2,644
SELECT T1.Product_Name FROM Products AS T1 JOIN Products_in_Events AS T2 ON T1.Product_ID = T2.Product_ID GROUP BY T1.Product_Name HAVING COUNT(*) >= 2
Show the names of products that are in at least two events.
CREATE TABLE Products (Product_Name VARCHAR, Product_ID VARCHAR); CREATE TABLE Products_in_Events (Product_ID VARCHAR)
Mostre os nomes dos produtos que estão em pelo menos dois eventos.
2,645
SELECT T1.Product_Name FROM Products AS T1 JOIN Products_in_Events AS T2 ON T1.Product_ID = T2.Product_ID GROUP BY T1.Product_Name HAVING COUNT(*) >= 2 ORDER BY T1.Product_Name
Show the names of products that are in at least two events in ascending alphabetical order of product name.
CREATE TABLE Products (Product_Name VARCHAR, Product_ID VARCHAR); CREATE TABLE Products_in_Events (Product_ID VARCHAR)
Mostre os nomes dos produtos que estão em pelo menos dois eventos em ordem alfabética ascendente do nome do produto.
2,646
SELECT Product_Name FROM Products WHERE NOT Product_ID IN (SELECT Product_ID FROM Products_in_Events)
List the names of products that are not in any event.
CREATE TABLE Products (Product_Name VARCHAR, Product_ID VARCHAR); CREATE TABLE Products_in_Events (Product_Name VARCHAR, Product_ID VARCHAR)
Listar os nomes dos produtos que não estão em qualquer evento.
2,647
SELECT COUNT(*) FROM artwork
How many artworks are there?
CREATE TABLE artwork (Id VARCHAR)
Quantas obras de arte existem?
2,648
SELECT Name FROM artwork ORDER BY Name
List the name of artworks in ascending alphabetical order.
CREATE TABLE artwork (Name VARCHAR)
Liste o nome das obras de arte em ordem alfabética ascendente.
2,649
SELECT Name FROM artwork WHERE TYPE <> "Program Talent Show"
List the name of artworks whose type is not "Program Talent Show".
CREATE TABLE artwork (Name VARCHAR, TYPE VARCHAR)
Liste o nome das obras de arte cujo tipo não é "Program Talent Show".
2,650
SELECT Festival_Name, LOCATION FROM festival_detail
What are the names and locations of festivals?
CREATE TABLE festival_detail (Festival_Name VARCHAR, LOCATION VARCHAR)
Quais são os nomes e locais dos festivais?
2,651
SELECT Chair_Name FROM festival_detail ORDER BY YEAR
What are the names of the chairs of festivals, sorted in ascending order of the year held?
CREATE TABLE festival_detail (Chair_Name VARCHAR, YEAR VARCHAR)
Quais são os nomes das cadeiras das festas, ordenadas em ordem ascendente do ano realizado?
2,652
SELECT LOCATION FROM festival_detail ORDER BY Num_of_Audience DESC LIMIT 1
What is the location of the festival with the largest number of audience?
CREATE TABLE festival_detail (LOCATION VARCHAR, Num_of_Audience VARCHAR)
Qual é a localização do festival com o maior número de público?
2,653
SELECT Festival_Name FROM festival_detail WHERE YEAR = 2007
What are the names of festivals held in year 2007?
CREATE TABLE festival_detail (Festival_Name VARCHAR, YEAR VARCHAR)
Quais são os nomes dos festivais realizados no ano de 2007?
2,654
SELECT AVG(Num_of_Audience) FROM festival_detail
What is the average number of audience for festivals?
CREATE TABLE festival_detail (Num_of_Audience INTEGER)
Qual é o número médio de público para festivais?
2,655
SELECT Festival_Name FROM festival_detail ORDER BY YEAR DESC LIMIT 3
Show the names of the three most recent festivals.
CREATE TABLE festival_detail (Festival_Name VARCHAR, YEAR VARCHAR)
Mostre os nomes dos três festivais mais recentes.
2,656
SELECT T2.Name, T3.Festival_Name FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID
For each nomination, show the name of the artwork and name of the festival where it is nominated.
CREATE TABLE artwork (Name VARCHAR, Artwork_ID VARCHAR); CREATE TABLE nomination (Artwork_ID VARCHAR, Festival_ID VARCHAR); CREATE TABLE festival_detail (Festival_Name VARCHAR, Festival_ID VARCHAR)
Para cada indicação, mostre o nome da obra de arte e o nome do festival onde ela é indicada.
2,657
SELECT DISTINCT T2.Type FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID WHERE T3.Year = 2007
Show distinct types of artworks that are nominated in festivals in 2007.
CREATE TABLE nomination (Artwork_ID VARCHAR, Festival_ID VARCHAR); CREATE TABLE festival_detail (Festival_ID VARCHAR, Year VARCHAR); CREATE TABLE artwork (Type VARCHAR, Artwork_ID VARCHAR)
Mostre tipos distintos de obras de arte que são nomeadas em festivais em 2007.
2,658
SELECT T2.Name FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID ORDER BY T3.Year
Show the names of artworks in ascending order of the year they are nominated in.
CREATE TABLE artwork (Name VARCHAR, Artwork_ID VARCHAR); CREATE TABLE nomination (Artwork_ID VARCHAR, Festival_ID VARCHAR); CREATE TABLE festival_detail (Festival_ID VARCHAR, Year VARCHAR)
Mostre os nomes das obras de arte em ordem crescente do ano em que foram nomeadas.
2,659
SELECT T3.Festival_Name FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID WHERE T2.Type = "Program Talent Show"
Show the names of festivals that have nominated artworks of type "Program Talent Show".
CREATE TABLE nomination (Artwork_ID VARCHAR, Festival_ID VARCHAR); CREATE TABLE artwork (Artwork_ID VARCHAR, Type VARCHAR); CREATE TABLE festival_detail (Festival_Name VARCHAR, Festival_ID VARCHAR)
Mostre os nomes dos festivais que nomearam obras de arte do tipo "Program Talent Show".
2,660
SELECT T1.Festival_ID, T3.Festival_Name FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID GROUP BY T1.Festival_ID HAVING COUNT(*) >= 2
Show the ids and names of festivals that have at least two nominations for artworks.
CREATE TABLE nomination (Festival_ID VARCHAR, Artwork_ID VARCHAR); CREATE TABLE festival_detail (Festival_Name VARCHAR, Festival_ID VARCHAR); CREATE TABLE artwork (Artwork_ID VARCHAR)
Mostre os IDs e nomes dos festivais que têm pelo menos duas indicações para obras de arte.
2,661
SELECT T1.Festival_ID, T3.Festival_Name, COUNT(*) FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID GROUP BY T1.Festival_ID
Show the id, name of each festival and the number of artworks it has nominated.
CREATE TABLE nomination (Festival_ID VARCHAR, Artwork_ID VARCHAR); CREATE TABLE festival_detail (Festival_Name VARCHAR, Festival_ID VARCHAR); CREATE TABLE artwork (Artwork_ID VARCHAR)
Mostre o id, o nome de cada festival e o número de obras de arte que ele nomeou.
2,662
SELECT TYPE, COUNT(*) FROM artwork GROUP BY TYPE
Please show different types of artworks with the corresponding number of artworks of each type.
CREATE TABLE artwork (TYPE VARCHAR)
Por favor, mostre diferentes tipos de obras de arte com o número correspondente de obras de arte de cada tipo.
2,663
SELECT TYPE FROM artwork GROUP BY TYPE ORDER BY COUNT(*) DESC LIMIT 1
List the most common type of artworks.
CREATE TABLE artwork (TYPE VARCHAR)
Liste o tipo mais comum de obras de arte.
2,664
SELECT YEAR FROM festival_detail GROUP BY YEAR HAVING COUNT(*) > 1
List the year in which there are more than one festivals.
CREATE TABLE festival_detail (YEAR VARCHAR)
Listar o ano em que há mais de um festival.
2,665
SELECT Name FROM Artwork WHERE NOT Artwork_ID IN (SELECT Artwork_ID FROM nomination)
List the name of artworks that are not nominated.
CREATE TABLE nomination (Name VARCHAR, Artwork_ID VARCHAR); CREATE TABLE Artwork (Name VARCHAR, Artwork_ID VARCHAR)
Liste o nome das obras de arte que não foram nomeadas.
2,666
SELECT Num_of_Audience FROM festival_detail WHERE YEAR = 2008 OR YEAR = 2010
Show the number of audience in year 2008 or 2010.
CREATE TABLE festival_detail (Num_of_Audience VARCHAR, YEAR VARCHAR)
Mostrar o número de audiências no ano de 2008 ou 2010.
2,667
SELECT SUM(Num_of_Audience) FROM festival_detail
What are the total number of the audiences who visited any of the festivals?
CREATE TABLE festival_detail (Num_of_Audience INTEGER)
Qual é o número total de espectadores que visitaram algum dos festivais?
2,668
SELECT YEAR FROM festival_detail WHERE LOCATION = 'United States' INTERSECT SELECT YEAR FROM festival_detail WHERE LOCATION <> 'United States'
In which year are there festivals both inside the 'United States' and outside the 'United States'?
CREATE TABLE festival_detail (YEAR VARCHAR, LOCATION VARCHAR)
Em que ano existem festivais dentro e fora dos Estados Unidos?
2,669
SELECT COUNT(*) FROM premises
How many premises are there?
CREATE TABLE premises (Id VARCHAR)
Quantas instalações existem?
2,670
SELECT DISTINCT premises_type FROM premises
What are all the distinct premise types?
CREATE TABLE premises (premises_type VARCHAR)
Quais são todos os tipos de premissas distintas?
2,671
SELECT premises_type, premise_details FROM premises ORDER BY premises_type
Find the types and details for all premises and order by the premise type.
CREATE TABLE premises (premises_type VARCHAR, premise_details VARCHAR)
Encontre os tipos e detalhes para todas as instalações e ordem pelo tipo de premissa.
2,672
SELECT premises_type, COUNT(*) FROM premises GROUP BY premises_type
Show each premise type and the number of premises in that type.
CREATE TABLE premises (premises_type VARCHAR)
Mostre cada tipo de premissa e o número de premissas nesse tipo.
2,673
SELECT product_category, COUNT(*) FROM mailshot_campaigns GROUP BY product_category
Show all distinct product categories along with the number of mailshots in each category.
CREATE TABLE mailshot_campaigns (product_category VARCHAR)
Mostrar todas as categorias de produtos distintas, juntamente com o número de mailshots em cada categoria.
2,674
SELECT customer_name, customer_phone FROM customers WHERE NOT customer_id IN (SELECT customer_id FROM mailshot_customers)
Show the name and phone of the customer without any mailshot.
CREATE TABLE customers (customer_name VARCHAR, customer_phone VARCHAR, customer_id VARCHAR); CREATE TABLE mailshot_customers (customer_name VARCHAR, customer_phone VARCHAR, customer_id VARCHAR)
Mostre o nome e o telefone do cliente sem qualquer mailshot.
2,675
SELECT T1.customer_name, T1.customer_phone FROM customers AS T1 JOIN mailshot_customers AS T2 ON T1.customer_id = T2.customer_id WHERE T2.outcome_code = 'No Response'
Show the name and phone for customers with a mailshot with outcome code 'No Response'.
CREATE TABLE customers (customer_name VARCHAR, customer_phone VARCHAR, customer_id VARCHAR); CREATE TABLE mailshot_customers (customer_id VARCHAR, outcome_code VARCHAR)
Mostre o nome e o telefone para os clientes com uma captura de e-mail com o código de resultado 'No Response'.
2,676
SELECT outcome_code, COUNT(*) FROM mailshot_customers GROUP BY outcome_code
Show the outcome code of mailshots along with the number of mailshots in each outcome code.
CREATE TABLE mailshot_customers (outcome_code VARCHAR)
Mostre o código de resultado dos mailshots juntamente com o número de mailshots em cada código de resultado.
2,677
SELECT T2.customer_name FROM mailshot_customers AS T1 JOIN customers AS T2 ON T1.customer_id = T2.customer_id WHERE outcome_code = 'Order' GROUP BY T1.customer_id HAVING COUNT(*) >= 2
Show the names of customers who have at least 2 mailshots with outcome code 'Order'.
CREATE TABLE customers (customer_name VARCHAR, customer_id VARCHAR); CREATE TABLE mailshot_customers (customer_id VARCHAR)
Mostre os nomes dos clientes que têm pelo menos 2 mailshots com o código de resultado 'Order'.
2,678
SELECT T2.customer_name FROM mailshot_customers AS T1 JOIN customers AS T2 ON T1.customer_id = T2.customer_id GROUP BY T1.customer_id ORDER BY COUNT(*) DESC LIMIT 1
Show the names of customers who have the most mailshots.
CREATE TABLE customers (customer_name VARCHAR, customer_id VARCHAR); CREATE TABLE mailshot_customers (customer_id VARCHAR)
Mostre os nomes dos clientes que têm mais mailshots.
2,679
SELECT T2.customer_name, T2.payment_method FROM mailshot_customers AS T1 JOIN customers AS T2 ON T1.customer_id = T2.customer_id WHERE T1.outcome_code = 'Order' INTERSECT SELECT T2.customer_name, T2.payment_method FROM mailshot_customers AS T1 JOIN customers AS T2 ON T1.customer_id = T2.customer_id WHERE T1.outcome_code = 'No Response'
What are the name and payment method of customers who have both mailshots in 'Order' outcome and mailshots in 'No Response' outcome.
CREATE TABLE customers (customer_name VARCHAR, payment_method VARCHAR, customer_id VARCHAR); CREATE TABLE mailshot_customers (customer_id VARCHAR, outcome_code VARCHAR)
Quais são o nome e o método de pagamento dos clientes que têm ambos os mailshots no resultado 'Order' e mailshots no resultado 'No Response'.
2,680
SELECT T2.premises_type, T1.address_type_code FROM customer_addresses AS T1 JOIN premises AS T2 ON T1.premise_id = T2.premise_id
Show the premise type and address type code for all customer addresses.
CREATE TABLE premises (premises_type VARCHAR, premise_id VARCHAR); CREATE TABLE customer_addresses (address_type_code VARCHAR, premise_id VARCHAR)
Mostre o tipo de premissa e o código do tipo de endereço para todos os endereços do cliente.
2,681
SELECT DISTINCT address_type_code FROM customer_addresses
What are the distinct address type codes for all customer addresses?
CREATE TABLE customer_addresses (address_type_code VARCHAR)
Quais são os códigos de tipo de endereço distintos para todos os endereços do cliente?
2,682
SELECT order_shipping_charges, customer_id FROM customer_orders WHERE order_status_code = 'Cancelled' OR order_status_code = 'Paid'
Show the shipping charge and customer id for customer orders with order status Cancelled or Paid.
CREATE TABLE customer_orders (order_shipping_charges VARCHAR, customer_id VARCHAR, order_status_code VARCHAR)
Mostre a taxa de envio e o ID do cliente para pedidos de clientes com status de pedido cancelado ou pago.
2,683
SELECT T1.customer_name FROM customers AS T1 JOIN customer_orders AS T2 ON T1.customer_id = T2.customer_id WHERE shipping_method_code = 'FedEx' AND order_status_code = 'Paid'
Show the names of customers having an order with shipping method FedEx and order status Paid.
CREATE TABLE customers (customer_name VARCHAR, customer_id VARCHAR); CREATE TABLE customer_orders (customer_id VARCHAR)
Mostrar os nomes dos clientes que têm uma encomenda com o método de envio FedEx e o estado da encomenda Pago.
2,684
SELECT COUNT(*) FROM COURSE
How many courses are there in total?
CREATE TABLE COURSE (Id VARCHAR)
Quantos cursos existem no total?
2,685
SELECT COUNT(*) FROM COURSE WHERE Credits > 2
How many courses have more than 2 credits?
CREATE TABLE COURSE (Credits INTEGER)
Quantos cursos têm mais de 2 créditos?
2,686
SELECT CName FROM COURSE WHERE Credits = 1
List all names of courses with 1 credit?
CREATE TABLE COURSE (CName VARCHAR, Credits VARCHAR)
Listar todos os nomes de cursos com 1 crédito?
2,687
SELECT CName FROM COURSE WHERE Days = "MTW"
Which courses are taught on days MTW?
CREATE TABLE COURSE (CName VARCHAR, Days VARCHAR)
Quais cursos são ministrados nos dias MTW?
2,688
SELECT COUNT(*) FROM DEPARTMENT WHERE Division = "AS"
What is the number of departments in Division "AS"?
CREATE TABLE DEPARTMENT (Division VARCHAR)
Qual é o número de departamentos na Divisão "AS"?
2,689
SELECT DPhone FROM DEPARTMENT WHERE Room = 268
What are the phones of departments in Room 268?
CREATE TABLE DEPARTMENT (DPhone VARCHAR, Room VARCHAR)
Quais são os telefones dos departamentos no quarto 268?
2,690
SELECT COUNT(DISTINCT StuID) FROM ENROLLED_IN WHERE Grade = "B"
Find the number of students that have at least one grade "B".
CREATE TABLE ENROLLED_IN (StuID VARCHAR, Grade VARCHAR)
Encontre o número de alunos que têm pelo menos um grau "B".
2,691
SELECT MAX(gradepoint), MIN(gradepoint) FROM GRADECONVERSION
Find the max and min grade point for all letter grade.
CREATE TABLE GRADECONVERSION (gradepoint INTEGER)
Encontre o ponto máximo e mínimo para todas as notas das letras.
2,692
SELECT DISTINCT Fname FROM STUDENT WHERE Fname LIKE '%a%'
Find the first names of students whose first names contain letter "a".
CREATE TABLE STUDENT (Fname VARCHAR)
Encontre os primeiros nomes dos alunos cujos primeiros nomes contenham a letra "a".
2,693
SELECT Fname, Lname FROM FACULTY WHERE sex = "M" AND Building = "NEB"
Find the first names and last names of male (sex is M) faculties who live in building NEB.
CREATE TABLE FACULTY (Fname VARCHAR, Lname VARCHAR, sex VARCHAR, Building VARCHAR)
Encontre os primeiros nomes e sobrenomes de homens (sexo é M) faculdades que vivem na construção NEB.
2,694
SELECT Room FROM FACULTY WHERE Rank = "Professor" AND Building = "NEB"
Find the rooms of faculties with rank professor who live in building NEB.
CREATE TABLE FACULTY (Room VARCHAR, Rank VARCHAR, Building VARCHAR)
Encontre as salas de faculdades com o professor que vive na construção de NEB.
2,695
SELECT DName FROM DEPARTMENT WHERE Building = "Mergenthaler"
Find the department name that is in Building "Mergenthaler".
CREATE TABLE DEPARTMENT (DName VARCHAR, Building VARCHAR)
Encontre o nome do departamento que está no Edifício "Mergenthaler".
2,696
SELECT * FROM COURSE ORDER BY Credits
List all information about courses sorted by credits in the ascending order.
CREATE TABLE COURSE (Credits VARCHAR)
Liste todas as informações sobre os cursos classificados por créditos na ordem ascendente.
2,697
SELECT CName FROM COURSE ORDER BY Credits
List the course name of courses sorted by credits.
CREATE TABLE COURSE (CName VARCHAR, Credits VARCHAR)
Liste o nome do curso dos cursos classificados por créditos.
2,698
SELECT Fname FROM STUDENT ORDER BY Age DESC
Find the first name of students in the descending order of age.
CREATE TABLE STUDENT (Fname VARCHAR, Age VARCHAR)
Encontre o primeiro nome dos alunos na ordem decrescente de idade.
2,699
SELECT LName FROM STUDENT WHERE Sex = "F" ORDER BY Age DESC
Find the last name of female (sex is F) students in the descending order of age.
CREATE TABLE STUDENT (LName VARCHAR, Sex VARCHAR, Age VARCHAR)
Encontre o sobrenome de estudantes do sexo feminino (sexo é F) na ordem decrescente de idade.