You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix "Can't determine which FROM clause to join from" SQLAlchemy error (#38)
Something changed in SQLAlchemy 1.3 after we upgraded (maybe in 5b02472?)
which caused the graph and matrix queries to start erroring, showing something like:
> InvalidRequestError("Can't determine which FROM clause to join from, there are
multiple FROMS which can join to this entity. Please use the .select_from() method
to establish an explicit left side, as well as providing an explcit ON clause if not
present already to help resolve the ambiguity.")
This fixes the errors by explicitly specifying which table to use as the FROM query.
From what I understand we only have this error if there are multiple joins in the same query.
The query in load_geomean_data also seemed to be missing a join on the samples table.
I guess SQLAlchemy must have previously inferred the join or something? Since the
relations go run -> sample -> test.
This affected both the sqlite and postgres backends, and I've tested this fixes the
error with both.
0 commit comments