sert121/SpiderSQL huggingface dataset:
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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 is the name and checking balance of the account which has the lowest savings balance?
SQL: SELECT T2.balance ,  T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid ORDER BY T3.balance LIMIT 1
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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: Find the name, checking balance and saving balance of all accounts in the bank.
SQL: SELECT T2.balance ,  T3.balance ,  T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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 names, checking balances, and savings balances for all customers?
SQL: SELECT T2.balance ,  T3.balance ,  T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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: Find the name, checking balance and savings balance of all accounts in the bank sorted by their total checking and savings balance in descending order.
SQL: SELECT T2.balance ,  T3.balance ,  T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid ORDER BY T2.balance + T3.balance DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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 names, checking balances, and savings balances of customers, ordered by the total of checking and savings balances descending?
SQL: SELECT T2.balance ,  T3.balance ,  T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid ORDER BY T2.balance + T3.balance DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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: Find the name of accounts whose checking balance is higher than corresponding saving balance.
SQL: SELECT T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid WHERE T2.balance  >  T3.balance
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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 names of customers with a higher checking balance than savings balance?
SQL: SELECT T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid WHERE T2.balance  >  T3.balance
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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: Find the name and total checking and savings balance of the accounts whose savings balance is lower than corresponding checking balance.
SQL: SELECT T1.name ,  T3.balance + T2.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid WHERE T3.balance  <  T2.balance
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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 names of customers who have a savings balance lower than their checking balance, and what is the total of their checking and savings balances?
SQL: SELECT T1.name ,  T3.balance + T2.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid  =  T2.custid JOIN savings AS T3 ON T1.custid  =  T3.custid WHERE T3.balance  <  T2.balance
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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: Find the name and savings balance of the top 3 accounts with the highest saving balance sorted by savings balance in descending order.
SQL: SELECT T1.name ,  T2.balance FROM accounts AS T1 JOIN savings AS T2 ON T1.custid  =  T2.custid ORDER BY T2.balance DESC LIMIT 3
-- Language PostgreSQL
        -- Tables: 
             -- Table: accounts 
columns : [['customer id', 'number'], ['name', 'text']]

 -- Table: savings 
columns : [['customer id', 'number'], ['balance', 'number']]

 -- Table: checking 
columns : [['customer id', 'number'], ['balance', 'number']]

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 names and savings balances of the three accounts with the highest savings balances?
SQL: SELECT T1.name ,  T2.balance FROM accounts AS T1 JOIN savings AS T2 ON T1.custid  =  T2.custid ORDER BY T2.balance DESC LIMIT 3
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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: How many main stream browsers whose market share is at least 5 exist?
SQL: SELECT count(*) FROM browser WHERE market_share  >=  5
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 the name of browsers in descending order by market share.
SQL: SELECT name FROM browser ORDER BY market_share DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 the ids, names and market shares of all browsers.
SQL: SELECT id ,  name ,  market_share FROM browser
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 is the maximum, minimum and average market share of the listed browsers?
SQL: SELECT max(market_share) ,  min(market_share) ,  avg(market_share) FROM browser
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 is the id and market share of the browser Safari?
SQL: SELECT id ,  market_share FROM browser WHERE name  =  'Safari'
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 name and os of web client accelerators that do not work with only a 'Broadband' type connection?
SQL: SELECT name ,  operating_system FROM web_client_accelerator WHERE CONNECTION != 'Broadband'
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 is the name of the browser that became compatible with the accelerator 'CProxy' after year 1998 ?
SQL: SELECT T1.name FROM browser AS T1 JOIN accelerator_compatible_browser AS T2 ON T1.id  =  T2.browser_id JOIN web_client_accelerator AS T3 ON T2.accelerator_id  =  T3.id WHERE T3.name  =  'CProxy' AND T2.compatible_since_year  >  1998
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 ids and names of the web accelerators that are compatible with two or more browsers?
SQL: SELECT T1.id ,  T1.Name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id  =  T1.id GROUP BY T1.id HAVING count(*)  >=  2
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 is the id and name of the browser that is compatible with the most web accelerators?
SQL: SELECT T1.id ,  T1.name FROM browser AS T1 JOIN accelerator_compatible_browser AS T2 ON T1.id  =  T2.browser_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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: When did the web accelerator 'CACHEbox' and browser 'Internet Explorer' become compatible?
SQL: SELECT T1.compatible_since_year FROM accelerator_compatible_browser AS T1 JOIN browser AS T2 ON T1.browser_id  =  T2.id JOIN web_client_accelerator AS T3 ON T1.accelerator_id  =  T3.id WHERE T3.name  =  'CACHEbox' AND T2.name  =  'Internet Explorer'
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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: How many different kinds of clients are supported by the web clients accelerators?
SQL: SELECT count(DISTINCT client) FROM web_client_accelerator
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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: How many accelerators are not compatible with the browsers listed ?
SQL: SELECT count(*) FROM web_client_accelerator WHERE id NOT IN ( SELECT accelerator_id FROM accelerator_compatible_browser );
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 distinct accelerator names are compatible with the browswers that have market share higher than 15?
SQL: SELECT DISTINCT T1.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id  =  T1.id JOIN browser AS T3 ON T2.browser_id  =  T3.id WHERE T3.market_share  >  15;
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 the names of the browser that are compatible with both 'CACHEbox' and 'Fasterfox'.
SQL: SELECT T3.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id  =  T1.id JOIN browser AS T3 ON T2.browser_id  =  T3.id WHERE T1.name  =  'CACHEbox' INTERSECT SELECT T3.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id  =  T1.id JOIN browser AS T3 ON T2.browser_id  =  T3.id WHERE T1.name  =  'Fasterfox'
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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 accelerator names and supporting operating systems that are not compatible with the browser named 'Opera'.
SQL: SELECT name ,  operating_system FROM web_client_accelerator EXCEPT SELECT T1.name ,  T1.operating_system FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id  =  T1.id JOIN browser AS T3 ON T2.browser_id  =  T3.id WHERE T3.name  =  'Opera'
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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: Which accelerator name contains substring "Opera"?
SQL: SELECT name FROM web_client_accelerator WHERE name LIKE "%Opera%"
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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: Find the number of web accelerators used for each Operating system.
SQL: SELECT Operating_system ,  count(*) FROM web_client_accelerator GROUP BY Operating_system
-- Language PostgreSQL
        -- Tables: 
             -- Table: web client accelerator 
columns : [['id', 'number'], ['name', 'text'], ['operating system', 'text'], ['client', 'text'], ['connection', 'text']]

 -- Table: browser 
columns : [['id', 'number'], ['name', 'text'], ['market share', 'number']]

 -- Table: accelerator compatible browser 
columns : [['accelerator id', 'number'], ['browser id', 'number'], ['compatible since year', 'number']]

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: give me names of all compatible browsers and accelerators in the descending order of compatible year
SQL: SELECT T2.name ,  T3.name FROM accelerator_compatible_browser AS T1 JOIN browser AS T2 ON T1.browser_id  =  T2.id JOIN web_client_accelerator AS T3 ON T1.accelerator_id  =  T3.id ORDER BY T1.compatible_since_year DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: How many wrestlers are there?
SQL: SELECT count(*) FROM wrestler
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: Count the number of wrestlers.
SQL: SELECT count(*) FROM wrestler
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 the names of wrestlers in descending order of days held.
SQL: SELECT Name FROM wrestler ORDER BY Days_held DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 names of the wrestlers, ordered descending by days held?
SQL: SELECT Name FROM wrestler ORDER BY Days_held DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 is the name of the wrestler with the fewest days held?
SQL: SELECT Name FROM wrestler ORDER BY Days_held ASC LIMIT 1
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: Return the name of the wrestler who had the lowest number of days held.
SQL: SELECT Name FROM wrestler ORDER BY Days_held ASC LIMIT 1
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 distinct reigns of wrestlers whose location is not "Tokyo,Japan" ?
SQL: SELECT DISTINCT Reign FROM wrestler WHERE LOCATION != "Tokyo , Japan"
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: Give the different reigns of wrestlers who are not located in Tokyo, Japan.
SQL: SELECT DISTINCT Reign FROM wrestler WHERE LOCATION != "Tokyo , Japan"
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 names and location of the wrestlers?
SQL: SELECT Name ,  LOCATION FROM wrestler
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: Give the names and locations of all wrestlers.
SQL: SELECT Name ,  LOCATION FROM wrestler
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 elimination moves of wrestlers whose team is "Team Orton"?
SQL: SELECT Elimination_Move FROM Elimination WHERE Team  =  "Team Orton"
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: Return the elimination movies of wrestlers on Team Orton.
SQL: SELECT Elimination_Move FROM Elimination WHERE Team  =  "Team Orton"
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 names of wrestlers and the elimination moves?
SQL: SELECT T2.Name ,  T1.Elimination_Move FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: Give the names of wrestlers and their elimination moves.
SQL: SELECT T2.Name ,  T1.Elimination_Move FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 the names of wrestlers and the teams in elimination in descending order of days held.
SQL: SELECT T2.Name ,  T1.Team FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID ORDER BY T2.Days_held DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 names of wrestlers and their teams in elimination, ordered descending by days held?
SQL: SELECT T2.Name ,  T1.Team FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID ORDER BY T2.Days_held DESC
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 the time of elimination of the wrestlers with largest days held.
SQL: SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID ORDER BY T2.Days_held DESC LIMIT 1
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 is the time of elimination for the wrestler with the most days held?
SQL: SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID ORDER BY T2.Days_held DESC LIMIT 1
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 times of elimination of wrestlers with days held more than 50.
SQL: SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID WHERE T2.Days_held  >  50
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 times of elimination for wrestlers with over 50 days held?
SQL: SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID WHERE T2.Days_held  >  50
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 different teams in eliminations and the number of eliminations from each team.
SQL: SELECT Team ,  COUNT(*) FROM elimination GROUP BY Team
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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: How many eliminations did each team have?
SQL: SELECT Team ,  COUNT(*) FROM elimination GROUP BY Team
-- Language PostgreSQL
        -- Tables: 
             -- Table: wrestler 
columns : [['wrestler id', 'number'], ['name', 'text'], ['reign', 'text'], ['days held', 'text'], ['location', 'text'], ['event', 'text']]

 -- Table: elimination 
columns : [['elimination id', 'text'], ['wrestler id', 'text'], ['team', 'text'], ['eliminated by', 'text'], ['elimination move', 'text'], ['time', '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 teams that have suffered more than three eliminations.
SQL: SELECT Team FROM elimination GROUP BY Team HAVING COUNT(*)  >  3