harelba / q

q - Run SQL directly on delimited files and multi-file sqlite databases
http://harelba.github.io/q/
GNU General Public License v3.0
10.19k stars 421 forks source link

Support subqueries in FROM and JOIN. #250

Open ChickenProp opened 3 years ago

ChickenProp commented 3 years ago

I may be missing something, but from my simple experiments so far this seems to work.

If you'd be amenable to adding this, I'll be happy to add tests and change documentation as necessary.

harelba commented 3 years ago

Hi @ChickenProp ! thanks for the PR.

I'm in the middle of a huge change inside q's code which should provide a large improvement. I'll take a deeper look into it when i'm done.

ChickenProp commented 2 years ago

@harelba gentle ping :) I see there's been some big changes, is this something you're in a position to look at now? (I confess I haven't actually checked if this still works.)

harelba commented 2 years ago

thanks for the ping @ChickenProp

Indeed, I've released a very large change, although it doesn't include changes to the query parsing itself.

I was planning a major change in query parsing, but it's a very big task, and most use-cases are covered by the current "parsing". I'll take a look to see if I can introduce a smaller change that will accommodate this use-case.