-- Database schema
| captain : Captain_ID [ INT ] primary_key , Name [ TEXT ] , Ship_ID [ INT ] captain.Ship_ID = Ship.Ship_ID , age [ TEXT ] , Class [ TEXT ] , Rank [ TEXT ] | Ship : Ship_ID [ INT ] primary_key , Name [ TEXT ] , Type [ TEXT ] , Built_Year [ INT ] , Class [ TEXT ] , Flag [ TEXT ] |
-- -- What are the names and flags of ships that do not have a captain with the rank of Midshipman?

SELECT name ,  flag FROM ship WHERE ship_id NOT IN (SELECT ship_id FROM captain WHERE rank  =  'Midshipman');