Question: Show the names and ids of tourist attractions that are visited at most once.
Schema: create table visits (tourist_attraction_id varchar, PRIMARY KEY (tourist_attraction_id)); create table tourist_attractions (name varchar, tourist_attraction_id varchar, PRIMARY KEY (name))
SQL: select t1.name, t1.tourist_attraction_id from tourist_attractions as t1 join visits as t2 on t1.tourist_attraction_id = t2.tourist_attraction_id group by t2.tourist_attraction_id having count(*) <= 1