datasette
datasette copied to clipboard
feat: allow joins using _through in both directions
Currently the _through clause can only work if the FK relationship is defined in a specific direction. I don't think there is any reason for this limitation, as an FK allows joining in both directions.
This is an admittedly hacky change to implement bidirectional joins using _through. It does work for our use-case, but I don't know if there are other implications that I haven't thought of. Also if this change is desirable we probably want to make the code a little nicer.