marijnh/Postmodern — pull request #38 by dimitri (2013-09-23 13:02:17+00:00)
Title: Rework bulk-copy API to allow several COPY within the same transaction. (#37)

Here's the patch implemented as you proposed, or at least my understanding of it. As we are moving away the control of the connection and transaction to the caller, I just removed any transaction management from the `close-db-writer` function.

I did try to implement a `with-copier` macro API in the postmodern package but as the API is used in 3 steps I don't think it makes much sense actually: first open, then write as many rows as you want to, then close.