CREATE TABLE table_name_30 (took_office VARCHAR, party VARCHAR, name VARCHAR)

Which Took Office that has a Party of democrat, under the name of John Hancock
SELECT took_office FROM table_name_30 WHERE party = "democrat" AND name = "john hancock"
SELECT "took_office" FROM "table_name_30" WHERE "democrat" = "party" AND "john hancock" = "name"