CREATE TABLE customers (customer_id NUMBER, customer_details CLOB)
CREATE TABLE settlements (settlement_id NUMBER, claim_id NUMBER, date_claim_made TIME, date_claim_settled TIME, amount_claimed NUMBER, amount_settled NUMBER, customer_policy_id NUMBER)
CREATE TABLE payments (payment_id NUMBER, settlement_id NUMBER, payment_method_code CLOB, date_payment_made TIME, amount_payment NUMBER)
CREATE TABLE customer_policies (policy_id NUMBER, customer_id NUMBER, policy_type_code CLOB, start_date TIME, end_date TIME)
CREATE TABLE claims (claim_id NUMBER, policy_id NUMBER, date_claim_made TIME, date_claim_settled TIME, amount_claimed NUMBER, amount_settled NUMBER)

Which claims had exactly one settlement? For each, tell me the the date the claim was made, the date it was settled and the amount settled.
SELECT T1.claim_id, T1.date_claim_made, T1.date_claim_settled FROM claims AS T1 JOIN settlements AS T2 ON T1.claim_id = T2.claim_id GROUP BY T1.claim_id HAVING COUNT(*) = 1
SELECT "T1"."claim_id", "T1"."date_claim_made", "T1"."date_claim_settled" FROM "claims" "T1" JOIN "settlements" "T2" ON "T1"."claim_id" = "T2"."claim_id" GROUP BY "T1"."claim_id" HAVING COUNT(*) = 1