mcfunley / pugsql

A HugSQL-inspired database library for Python
https://pugsql.org
Apache License 2.0
681 stars 22 forks source link

Support multiple queries per file #16

Closed mcfunley closed 4 years ago

mcfunley commented 5 years ago

HugSQL doesn't make you put one query in one file. It's pretty reasonable.

If we wind up parsing queries ourselves for any other reason, the sqlparse library has a function that will split a file into sql queries. We could use this.

We might want to also extend module so that it works if it's given a single file. (This isn't super useful with one function per file, so it doesn't work now).

mcfunley commented 4 years ago

This was implemented a few versions back