What is the document id with 1 to 2 paragraphs?
create table paragraphs (document_id varchar, PRIMARY KEY (document_id))
select document_id from paragraphs group by document_id having count(*) between 1 and 2