![](/static/253f0d9b/assets/icons/icon-96x96.png)
![](https://beehaw.org/pictrs/image/c0e83ceb-b7e5-41b4-9b76-bfd152dd8d00.png)
ooo, I love this. It reminds me of how nice C#'s LINQ is…
“Pipeline style” DB queries have some interesting advantages as well:
- It’s straightforward to write efficient queries for DBs that don’t include a query optimizer stares at Datomic
- You can split the pipeline into server-side and client-side steps when working with less capable DBs stares at most of NoSQL
- It would be much easier to transition from a pipeline API to a non-text-based API so that our ORMs/query builders can directly talk to DBs without the overhead of generating and parsing SQL.
The funny thing is that YouTube’s code is already so laggy that we all believed this without a second thought.