Dataset Viewer
Auto-converted to Parquet Duplicate
system
stringlengths
323
8.06k
conversations
listlengths
6
56
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE token_metas ( block_timestamp timestamp, block_number bigint, transaction_hash varch...
[ { "role": "user", "content": "List all ERC20 tokens from token_metas that are marked as a proxy (is_proxy = 1). Show their contract address, symbol, and name.", "sql": null }, { "role": "assistant", "content": "SELECT contract_address, symbol, name FROM token_metas WHERE is_erc20 = 1 AND is_...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE government_services.service_locations ( location_id character varying(64) NOT NULL, ...
[ { "role": "user", "content": "I want to know the total number of appointments per location along with the location name for appointments scheduled in March 2024.", "sql": null }, { "role": "assistant", "content": "SELECT\n sl.location_name,\n COUNT(a.appointment_id) AS appointment_count\nF...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE gaming_technology.players ( player_id uuid NOT NULL DEFAULT gen_random_uuid(), -...
[ { "role": "user", "content": "I'd like a list of all games, displaying game title, developer name, and total number of achievements for each game.", "sql": null }, { "role": "assistant", "content": "SELECT g.title, d.name AS developer_name, COUNT(a.achievement_id) AS total_achievements\nFROM...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE legal_services.cases ( case_id text, case_number text, case_name text, client_id tex...
[ { "role": "user", "content": "Show me all cases that are associated with the court jurisdiction 'Federal Court'.", "sql": null }, { "role": "assistant", "content": "SELECT * FROM legal_services.cases WHERE court_jurisdiction = 'Federal Court';", "sql": null }, { "role": "user", ...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE social_media.post_hashtags ( post_hashtag_id.text, post_id.text, hashtag_id.text ) C...
[ { "role": "user", "content": "List all conversation participants along with post_hashtag details where the participant's user_id matches the hashtag_id.", "sql": null }, { "role": "assistant", "content": "SELECT cp.conversation_id, cp.user_id, ph.post_id, ph.hashtag_id\nFROM social_media.con...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE healthcare.insurance_plans ( plan_id text, plan_name text, insurance_provider text, ...
[ { "role": "user", "content": "Please list the contact phone number and website for each insurance plan.", "sql": null }, { "role": "assistant", "content": "SELECT plan_id, plan_name, contact_phone, website FROM healthcare.insurance_plans;", "sql": null }, { "role": "user", "c...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE hospitality_technology.rooms ( room_id text PRIMARY KEY, property_id text, room_numb...
[ { "role": "user", "content": "List the room_id, room_number, and current_condition for all rooms that have 'Jacuzzi' in their features.", "sql": null }, { "role": "assistant", "content": "SELECT room_id, room_number, current_condition\nFROM hospitality_technology.rooms\nWHERE features LIKE '...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE trading_platform.users ( user_id text PRIMARY KEY, username text, email text, passwo...
[ { "role": "user", "content": "Show me each completed order with order_id, the username of the user who placed it, asset_id, quantity, and price.", "sql": null }, { "role": "assistant", "content": "SELECT\n o.order_id,\n u.username,\n o.asset_id,\n o.quantity,\n o.price\nFROM trading_pla...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE transportation.routes ( route_id text, route_number text, description text, origin_l...
[ { "role": "user", "content": "Find all pairs of different routes where the estimated duration in minutes is identical. For each pair, show both route IDs, their route numbers, and the shared duration.", "sql": null }, { "role": "assistant", "content": "SELECT r1.route_id AS route1_id, r1.rou...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE transportation.drivers ( driver_id text PRIMARY KEY, employee_id text, first_name te...
[ { "role": "user", "content": "Retrieve the route number and description for routes whose estimated duration exceeds 120 minutes.", "sql": null }, { "role": "assistant", "content": "SELECT route_number, description\nFROM transportation.routes\nWHERE estimated_duration_minutes > 120;", "sq...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE financial_services.accounts ( account_id character varying(64) NOT NULL, customer_id...
[ { "role": "user", "content": "Show me each account along with any loans linked to it. Include the account type, account balance, loan type, and loan principal amount.", "sql": null }, { "role": "assistant", "content": "SELECT a.account_type, a.balance, l.loan_type, l.principal_amount FROM fi...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE insurance.policies ( policy_id character varying(64) NOT NULL, customer_id character...
[ { "role": "user", "content": "List all policies that have a coverage limit greater than 750000 and a premium amount greater than 1000. Show the policy number, product ID, coverage limit, and premium amount.", "sql": null }, { "role": "assistant", "content": "SELECT\n policy_number,\n produ...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE social_media.users ( user_id text, username text, email text, password_hash text, fu...
[ { "role": "user", "content": "List the usernames and email addresses of users who have participated in group chats, along with the names of those group chats.", "sql": null }, { "role": "assistant", "content": "SELECT u.username, u.email, c.group_name\nFROM social_media.users u\nJOIN social_...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE government_services.citizens ( citizen_id character varying(64) NOT NULL, national_i...
[ { "role": "user", "content": "Which cities are listed as primary_address for citizens who have a verified account? Can you show the city names and the number of verified citizens in each city?", "sql": null }, { "role": "assistant", "content": "SELECT SPLIT_PART(primary_address, ',', 1) AS c...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE gaming_technology.players ( player_id uuid PRIMARY KEY, username text, email text, p...
[ { "role": "user", "content": "I want to get the number of servers and the average current players for each game, including the game title.", "sql": null }, { "role": "assistant", "content": "SELECT g.title,\n COUNT(s.server_id) AS server_count,\n AVG(s.current_players) AS avg_cur...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE healthcare.patients ( patient_id.text, first_name.text, last_name.text, date_of_birt...
[ { "role": "user", "content": "Show all diagnoses recorded by doctor with ID 'doc789'. Include the diagnosis ID, patient ID, description, and diagnosis date.", "sql": null }, { "role": "assistant", "content": "SELECT diagnosis_id, patient_id, description, diagnosis_date FROM healthcare.diagno...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE web3.tokens ( token_id character varying(64) NOT NULL, -- unique identifier for...
[ { "role": "user", "content": "Count how many tokens exist for each contract_address.", "sql": null }, { "role": "assistant", "content": "SELECT contract_address,\n COUNT(*) AS token_count\nFROM web3.tokens\nGROUP BY contract_address;", "sql": null }, { "role": "user", "...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE government_services.agencies ( agency_id character varying(64) NOT NULL, agency_name...
[ { "role": "user", "content": "List the full name of employees and the names of the agencies they work for, but only for employees who are currently employed.", "sql": null }, { "role": "assistant", "content": "SELECT e.first_name || ' ' || e.last_name AS employee_full_name, a.agency_name\nFR...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE financial_services.customers ( customer_id text, first_name text, last_name text, da...
[ { "role": "user", "content": "Show me for each loan_type, the total number of loans and the average principal_amount, along with the average account balance for the accounts associated with those loans.", "sql": null }, { "role": "assistant", "content": "SELECT l.loan_type, COUNT(l.loan_id) ...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE project_fundraising_record ( id character varying(32) NOT NULL, -- fundraising reco...
[ { "role": "user", "content": "Show me the top 5 projects by valuation that completed fundraising rounds in the last 3 months, along with their narrative information if available.", "sql": null }, { "role": "assistant", "content": "SELECT pfr.project_name, pfr.valuation, pfr.rounds_name, pfr....
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE legal_services.documents ( document_id.text, case_id.text, document_name.text, docum...
[ { "role": "user", "content": "Find documents that have the same document_name but are associated with different cases. Show the document name and the two different case IDs.", "sql": null }, { "role": "assistant", "content": "SELECT d1.document_name, d1.case_id AS case_id_1, d2.case_id AS ca...
You are an expert in writing database language. You can write a corresponding database language query to answer the user's question based on the table structure described by the table creation statement. ##Table Structure CREATE TABLE transportation.vehicles ( vehicle_id character varying(64) NOT NULL, license_plate c...
[ { "role": "user", "content": "For each passenger, compute the count of bookings and average fare for bookings made in February 2024.", "sql": null }, { "role": "assistant", "content": "SELECT p.passenger_id, COUNT(b.booking_id) AS booking_count, AVG(b.fare) AS avg_fare\nFROM transportation.p...
End of preview. Expand in Data Studio

No dataset card yet

Downloads last month
2