Skip to content

Exploratory Data Analysis using SQL :Applied Data Science Capstone (Applied Data Science Specialization) Answers 2025

Question 1

Which of the following will retrieve up to 20 records from the spacex table?

  • SELECT TOP 20 rows from SPACEXTBL

  • SELECT * from SPACEXTBL where count(*)=20

  • SELECT * from SPACEXTBL MAX 20

  • SELECT * from SPACEXTBL LIMIT 20

Explanation: LIMIT 20 is the correct SQL clause (MySQL/Postgres/SQLite) to return up to 20 rows.


Question 2

Which of the following queries display the minimum payload mass?

  • select min(payload_mass__kg_) from SPACEXTBL

  • select payload_mass__kg_ from SPACEXTBL order by payload_mass__kg_ desc LIMIT 1

  • select payload_mass__kg_ from SPACEXTBL where payload_mass__kg_=(select max(payload_mass__kg_) from SPACEXTBL) LIMIT 1

  • select payload_mass__kg_ from SPACEXTBL order by payload_mass__kg_ group by booster_version LIMIT 1

Explanation: MIN() returns the minimum value directly; the others either return the maximum or are incorrectly formed.


Question 3

Which query gives total payload mass in a column named Total_Payload_Mass?

  • SELECT sum(PAYLOAD_MASS__KG_) from SPACEXTBL

  • SELECT count(PAYLOAD_MASS__KG_) as Total_Payload_Mass from SPACEXTBL

  • SELECT sum(PAYLOAD_MASS__KG_) as Total_Payload_Mass from SPACEXTBL

Explanation: SUM(...) AS Total_Payload_Mass computes the total and names the result column as required.


Question 4

Which query displays mission outcome counts for each launch site?

  • select count("Mission_Outcome") as MISSION_OUTCOME_COUNT,Launch_Site from SPACEXTBL group by "Launch_Site";

  • select sum("Mission_Outcome") as MISSION_OUTCOME_COUNT,Launch_Site from SPACEXTBL group by "Launch_Site";

Explanation: COUNT() gives counts per launch site. SUM() would add numeric values (only valid if Mission_Outcome is numeric and you wanted the sum).


Question 5

What are the unique launch sites mentioned in the Spacex table?

  • ❌ None of the Above

  • ❌ CCAFS LC-40,KSC LC-39B,VAFB SLC-4k , CCAFS SLC-40

  • ❌ CCAS LC-40,KSC LC-39A,VAFB SLC-4E , CCAFS SLC-80

  • CCAFS LC-40,KSC LC-39A, VAFB SLC-4E , CCAFS SLC-40

Explanation: The list with KSC LC-39A and VAFB SLC-4E matches the typical dataset site names; the other options contain typos or incorrect site identifiers.


🧾 Summary Table

Q# Correct answer Why
1 SELECT * from SPACEXTBL LIMIT 20 LIMIT returns up to N rows
2 select min(payload_mass__kg_) from SPACEXTBL MIN() returns minimum value
3 SELECT sum(PAYLOAD_MASS__KG_) as Total_Payload_Mass from SPACEXTBL SUM(...) AS ... computes and names total
4 select count("Mission_Outcome") as MISSION_OUTCOME_COUNT, Launch_Site ... group by COUNT() per group yields counts
5 CCAFS LC-40, KSC LC-39A, VAFB SLC-4E, CCAFS SLC-40 Correct set of launch-site names (others have typos)