29 ms·
SQLalchemy is exceptionally good at all of these -- and I'm not even a power user so I don't know all the tricks. Re: Composability You can generate something
by grouseway 5y ago
SQLalchemy is exceptionally good at all of these -- and I'm not even a power user so I don't know all the tricks.
Re: Composability
You can generate something like the WHERE clause of a query in a function and return it alone (rather than as a SELECT query) or even combine it with another WHERE.
e.g. In SA the "select" and "where" portions aren't tightly coupled.
Re: Expressivity
Right now you can easily build up ef.core queries by chaining IQueryable.Where, which is nice but you can only do that for selects and something like OR conditions are difficult to implement.
e.g. in SA you can just pass a list of predicates to the or_() function.
e.g. in SA you can build a WHERE clause and then pass the same clause to a select or a bulk operation.