SQL
stringlengths
18
577
question
stringlengths
317
11.5k
SELECT commod FROM sampledata15 WHERE origin = 2 AND commod not in (SELECT commod FROM sampledata15 WHERE origin = 1)
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Name some imported commodities that are not found in the US.
SELECT T1.growst, avg(T2.concen) FROM sampledata15 as T1 JOIN resultsdata15 as T2 ON T1.sample_pk = T2.sample_pk GROUP BY T1.growst
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Tell me the average pesticide residue for each state in the US where food is grown.
SELECT T1.variety FROM resultsdata15 as T2 JOIN sampledata15 as T1 ON T1.sample_pk = T2.sample_pk WHERE T2.commod = "AP" GROUP BY T1.variety ORDER BY sum(T2.concen) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which varieties of apple typically have higher pesticide levels?
SELECT commod FROM resultsdata15 WHERE concen > lod
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which commodities have the pesticides concentration much higher than their limit for detection?
SELECT lab FROM resultsdata15 GROUP BY lab ORDER BY count(*) DESC LIMIT 5
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Name top 5 labs with the maximum number of testing.
SELECT T1.country FROM sampledata15 as T1 JOIN resultsdata15 as T2 ON T1.sample_pk = T2.sample_pk GROUP BY T1.country ORDER BY sum(T2.concen) LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which country is the safest in terms of the pesticide concentration found in imported foods?
SELECT distst FROM sampledata15 GROUP BY distst ORDER BY count(*) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which is the most popular state in the US in terms of commodities distribution?
SELECT max(concen) FROM resultsdata15
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What is the maximum pesticide concentration ever found in a commodity?
SELECT year, month, day FROM sampledata15 WHERE sample_pk = 3763
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. When is sample 3763 collected?
SELECT distst FROM sampledata15 WHERE commod = "AP" GROUP BY distst ORDER BY count(*) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which state has the most apple collected?
SELECT growst FROM sampledata15 WHERE commod = "AP" GROUP BY growst ORDER BY count(*) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which state has grow the most apples?
SELECT count(DISTINCT variety) FROM sampledata15
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. How many class of products are there?
SELECT site FROM sampledata15 WHERE sample_pk = 3763
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. what's the 4 digit collection code of sample 3763?
SELECT country FROM sampledata15 WHERE sample_pk = 6480 AND origin = 2
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. If sample 6480 is imported, which country is it originally from?
SELECT quantity FROM sampledata15 WHERE sample_pk = 9628
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. How many number of units are there in sample 9628?
SELECT testclass FROM resultsdata15 WHERE sample_pk = 7498
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What's the code for test for sample 7498?
SELECT confmethod FROM resultsdata15 as T2 JOIN sampledata15 as T1 ON T1.sample_pk = T2.sample_pk ORDER BY year, month, day DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What's the code for confirmation for the latest sample?
SELECT lab FROM resultsdata15 GROUP BY lab ORDER BY count(*) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which lab has analyzed the most sample?
SELECT max(testclass) FROM resultsdata15
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What's the majority of test classification result?
SELECT conunit FROM resultsdata15 WHERE sample_pk = 3879
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What's the unit of measure for sample 3879?
SELECT conunit FROM resultsdata15 WHERE commod = "PO"
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What's the unit of measure used for the product commodity code PO?
SELECT mean FROM resultsdata15 WHERE commod = "AP"
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What's the mean result finding for product AP?
SELECT max(extract) FROM resultsdata15
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What's the most common extraction method?
SELECT lab FROM resultsdata15 GROUP BY lab ORDER BY count(*) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which lab conduct of most number of tests?
SELECT lab FROM resultsdata15 WHERE commod = "AP"
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which lab is used for testing for prodict AP?
SELECT count(*) FROM sampledata15 WHERE origin = "2"
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. How many samples come from other countries?
SELECT commod FROM resultsdata15 WHERE mean = "A" GROUP BY commod ORDER BY count(*) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What kind of food has been tested 'detect' most?
SELECT state FROM sampledata15 WHERE claim = "PO" GROUP BY state ORDER BY count(*) DESC LIMIT 1
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which state produce the most organic food?
SELECT max(country) FROM sampledata15
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Where do the US import the most food ?
SELECT max(commod) FROM resultsdata15
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. What kind of food has been test the most?
SELECT max(pestcode) FROM resultsdata15
Given the Table sampledata15 having columns as sample_pk has datatype number, state has datatype text, year has datatype text, month has datatype text, day has datatype text, site has datatype text, commod has datatype text, source_id has datatype text, variety has datatype text, origin has datatype text, country has datatype text, disttype has datatype text, commtype has datatype text, claim has datatype text, quantity has datatype number, growst has datatype text, packst has datatype text, distst has datatype text which has sample pk and Given the Table resultsdata15 having columns as sample_pk has datatype number, commod has datatype text, commtype has datatype text, lab has datatype text, pestcode has datatype text, testclass has datatype text, concen has datatype number, lod has datatype number, conunit has datatype text, confmethod has datatype text, confmethod2 has datatype text, annotate has datatype text, quantitate has datatype text, mean has datatype text, extract has datatype text, determin has datatype text which has sample pk. Answer the question by writing the appropriate SQL code. Which kind of pesticide is the easiest to be tested?
SELECT Country FROM nuclear_power_plants WHERE Status = "Operational" GROUP BY Country ORDER BY count(Name) DESC LIMIT 10
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the top 10 countries with most number of operational plants?
SELECT Name, Country FROM nuclear_power_plants WHERE Status = "Planned"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the planed nuclear power plants and their located countries?
SELECT ReactorModel FROM nuclear_power_plants GROUP BY ReactorModel ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What’s the most used nuclear reactor model?
SELECT Country FROM nuclear_power_plants WHERE Name = "Kaiga-4"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country is Kaiga-4 built in?
SELECT count(*) FROM nuclear_power_plants WHERE ReactorType = "PHWR"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many PHWR are there today?
SELECT count(DISTINCT ReactorModel) FROM nuclear_power_plants
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many kinds of nuclear reactor model in the world?
SELECT count(*) FROM nuclear_power_plants WHERE Status = "Shutdown"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many nuclear power plants were shut down now?
SELECT Country FROM nuclear_power_plants Group BY Country HAVING count(Name) > 3
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many countries have at least 3 nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY count(name) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country HAVING count(Name) = 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has only one nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Capacity) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most capacities of nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Capacity) LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the least capacities of nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Name) DESC LIMIT 3
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the top 3 countries which have the most nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY count(Name) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most nuclear station?
SELECT Country FROM nuclear_power_plants WHERE Status = "Shutdown" GROUP BY Country ORDER BY count(Name) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which county has the most nuclear station shut down?
SELECT Name FROM nuclear_power_plants ORDER BY Capacity DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What nuclear station has the largest nuclear power plant capacity?
SELECT count(*) FROM nuclear_power_plants WHERE Country = "France" and Status = "Operational"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many operating nuclear station in France?
SELECT count(Name) FROM nuclear_power_plants WHERE Status = "Under Construction"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many nuclear station are under construction?
SELECT ReactorModel FROM nuclear_power_plants GROUP BY ReactorModel ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What nuclear reactor model is the most popular?
SELECT Country FROM nuclear_power_plants WHERE Name = "Chinon-A3"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country is Chinon-A3 in?
SELECT Name FROM nuclear_power_plants where Status = "Operational" and Country = "Japan"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are operational nuclear power plants in Japan called?
SELECT Country FROM nuclear_power_plants ORDER BY OperationalFrom LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country first started using nuclear power plant(s)?
SELECT count(*) FROM nuclear_power_plants WHERE Country = "Japan" AND Status = "Under Construction"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many nuclear power plants are in preparation to be used in Japan?
SELECT Status FROM nuclear_power_plants WHERE Country = "United States" ORDER BY Capacity DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What is the current situation of the nuclear power plant in the United States with the maximum capacity?
SELECT max(Capacity) FROM nuclear_power_plants WHERE ReactorType = "PWR" and Status = "Operational"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What is the maximum capacity of existing pressurized water reactor?
SELECT Country FROM nuclear_power_plants WHERE Status = "Under Construction" GROUP BY Country ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which nation has the most nuclear plants under construction?
SELECT Country FROM nuclear_power_plants WHERE Status = "Under Construction" GROUP BY Country ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most under constriction power plants to date?
SELECT Longitude, Latitude FROM nuclear_power_plants WHERE ReactorType = "BWR" ORDER BY ConstructionStartAt LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Where is the first BWR type power plant built and located?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Capacity) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country lead the total capacity of the power plants it held?
SELECT Source FROM nuclear_power_plants GROUP BY Source ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What is the main source of the information for this table?
SELECT ReactorType FROM nuclear_power_plants GROUP BY ReactorType ORDER BY avg(Capacity) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which reactor type has the largest average capacity?
SELECT Country FROM nuclear_power_plants WHERE Name = "Kursk-1"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country is Kursk-1 in?
SELECT Country FROM nuclear_power_plants WHERE Status = "Operational" GROUP BY Country ORDER BY count(Name) DESC LIMIT 10
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the top 10 countries with most number of operational plants?
SELECT Name, Country FROM nuclear_power_plants WHERE Status = "Planned"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the planed nuclear power plants and their located countries?
SELECT ReactorModel FROM nuclear_power_plants GROUP BY ReactorModel ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What’s the most used nuclear reactor model?
SELECT Country FROM nuclear_power_plants WHERE Name = "Kaiga-4"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country is Kaiga-4 built in?
SELECT count(*) FROM nuclear_power_plants WHERE ReactorType = "PHWR"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many PHWR are there today?
SELECT count(DISTINCT ReactorModel) FROM nuclear_power_plants
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many kinds of nuclear reactor model in the world?
SELECT count(*) FROM nuclear_power_plants WHERE Status = "Shutdown"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many nuclear power plants were shut down now?
SELECT Country FROM nuclear_power_plants Group BY Country HAVING count(Name) > 3
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many countries have at least 3 nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY count(name) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country HAVING count(Name) = 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has only one nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Capacity) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most capacities of nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Capacity) LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the least capacities of nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Name) DESC LIMIT 3
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the top 3 countries which have the most nuclear power plants?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY count(Name) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most nuclear station?
SELECT Country FROM nuclear_power_plants WHERE Status = "Shutdown" GROUP BY Country ORDER BY count(Name) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which county has the most nuclear station shut down?
SELECT Name FROM nuclear_power_plants ORDER BY Capacity DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What nuclear station has the largest nuclear power plant capacity?
SELECT count(*) FROM nuclear_power_plants WHERE Country = "France" and Status = "Operational"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many operating nuclear station in France?
SELECT count(Name) FROM nuclear_power_plants WHERE Status = "Under Construction"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many nuclear station are under construction?
SELECT ReactorModel FROM nuclear_power_plants GROUP BY ReactorModel ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What nuclear reactor model is the most popular?
SELECT Country FROM nuclear_power_plants WHERE Name = "Chinon-A3"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country is Chinon-A3 in?
SELECT Name FROM nuclear_power_plants where Status = "Operational" and Country = "Japan"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are operational nuclear power plants in Japan called?
SELECT Country FROM nuclear_power_plants ORDER BY OperationalFrom LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country first started using nuclear power plant(s)?
SELECT count(*) FROM nuclear_power_plants WHERE Country = "Japan" AND Status = "Under Construction"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How many nuclear power plants are in preparation to be used in Japan?
SELECT Status FROM nuclear_power_plants WHERE Country = "United States" ORDER BY Capacity DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What is the current situation of the nuclear power plant in the United States with the maximum capacity?
SELECT max(Capacity) FROM nuclear_power_plants WHERE ReactorType = "PWR" and Status = "Operational"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What is the maximum capacity of existing pressurized water reactor?
SELECT Country FROM nuclear_power_plants WHERE Status = "Under Construction" GROUP BY Country ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which nation has the most nuclear plants under construction?
SELECT Country FROM nuclear_power_plants WHERE Status = "Under Construction" GROUP BY Country ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country has the most under constriction power plants to date?
SELECT Longitude, Latitude FROM nuclear_power_plants WHERE ReactorType = "BWR" ORDER BY ConstructionStartAt LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Where is the first BWR type power plant built and located?
SELECT Country FROM nuclear_power_plants GROUP BY Country ORDER BY sum(Capacity) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country lead the total capacity of the power plants it held?
SELECT Source FROM nuclear_power_plants GROUP BY Source ORDER BY count(*) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What is the main source of the information for this table?
SELECT ReactorType FROM nuclear_power_plants GROUP BY ReactorType ORDER BY avg(Capacity) DESC LIMIT 1
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which reactor type has the largest average capacity?
SELECT Country FROM nuclear_power_plants WHERE Name = "Kursk-1"
Given the Table nuclear power plants having columns as Id has datatype text, Name has datatype text, Latitude has datatype text, Longitude has datatype text, Country has datatype text, Status has datatype text, ReactorType has datatype text, ReactorModel has datatype text, ConstructionStartAt has datatype text, OperationalFrom has datatype text, OperationalTo has datatype text, Capacity has datatype text, LastUpdatedAt has datatype text, Source has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. Which country is Kursk-1 in?
SELECT T2.state FROM FINREV_FED_KEY_17 as T2 JOIN FINREV_FED_17 as T1 ON T1.state_code = T2.State_Code GROUP BY T1.state_code ORDER BY sum(t_fed_rev)
Given the Table finrev fed 17 having columns as state_code has datatype number, idcensus has datatype number, school_district has datatype text, nces_id has datatype text, yr_data has datatype number, t_fed_rev has datatype number, c14 has datatype number, c25 has datatype number which has NO_PRIMARY_KEY and Given the Table ndecoreexcel math grade8 having columns as year has datatype number, state has datatype text, all_students has datatype text, average_scale_score has datatype number which has NO_PRIMARY_KEY and Given the Table finrev fed key 17 having columns as State_Code has datatype number, State has datatype text, #_Records has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the top five states in descending order in terms of revenue provided to school districts?
SELECT T2.state FROM FINREV_FED_17 as T1 JOIN FINREV_FED_KEY_17 as T2 ON T1.state_code = T2.state_code GROUP BY T2.state ORDER BY count(school_district) DESC LIMIT 5
Given the Table finrev fed 17 having columns as state_code has datatype number, idcensus has datatype number, school_district has datatype text, nces_id has datatype text, yr_data has datatype number, t_fed_rev has datatype number, c14 has datatype number, c25 has datatype number which has NO_PRIMARY_KEY and Given the Table ndecoreexcel math grade8 having columns as year has datatype number, state has datatype text, all_students has datatype text, average_scale_score has datatype number which has NO_PRIMARY_KEY and Given the Table finrev fed key 17 having columns as State_Code has datatype number, State has datatype text, #_Records has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. What are the top five states in descending order in terms of the number of school districts per state?
SELECT state, max(year) FROM NDECoreExcel_Math_Grade8 GROUP BY state
Given the Table finrev fed 17 having columns as state_code has datatype number, idcensus has datatype number, school_district has datatype text, nces_id has datatype text, yr_data has datatype number, t_fed_rev has datatype number, c14 has datatype number, c25 has datatype number which has NO_PRIMARY_KEY and Given the Table ndecoreexcel math grade8 having columns as year has datatype number, state has datatype text, all_students has datatype text, average_scale_score has datatype number which has NO_PRIMARY_KEY and Given the Table finrev fed key 17 having columns as State_Code has datatype number, State has datatype text, #_Records has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. For each state, when was the last time the average score data was collected?
SELECT t_fed_rev FROM FINREV_FED_17 WHERE school_district = "FAIRFAX CO SCHS"
Given the Table finrev fed 17 having columns as state_code has datatype number, idcensus has datatype number, school_district has datatype text, nces_id has datatype text, yr_data has datatype number, t_fed_rev has datatype number, c14 has datatype number, c25 has datatype number which has NO_PRIMARY_KEY and Given the Table ndecoreexcel math grade8 having columns as year has datatype number, state has datatype text, all_students has datatype text, average_scale_score has datatype number which has NO_PRIMARY_KEY and Given the Table finrev fed key 17 having columns as State_Code has datatype number, State has datatype text, #_Records has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How much federal funding did Faifaix County, VA schools receive in all forms?
SELECT sum(c14) FROM FINREV_FED_17 WHERE yr_data = 17
Given the Table finrev fed 17 having columns as state_code has datatype number, idcensus has datatype number, school_district has datatype text, nces_id has datatype text, yr_data has datatype number, t_fed_rev has datatype number, c14 has datatype number, c25 has datatype number which has NO_PRIMARY_KEY and Given the Table ndecoreexcel math grade8 having columns as year has datatype number, state has datatype text, all_students has datatype text, average_scale_score has datatype number which has NO_PRIMARY_KEY and Given the Table finrev fed key 17 having columns as State_Code has datatype number, State has datatype text, #_Records has datatype text which has NO_PRIMARY_KEY. Answer the question by writing the appropriate SQL code. How much did the federal government spend in No Child Left Behind funding in 2017?