3 ms·
Just looked at LINQ and it looks like Ecto [0] used a lot of its ideas for inspiration! I haven't used LINQ, but in Ecto, there are so many useful constructs fo
by dqv 3y ago
Just looked at LINQ and it looks like Ecto [0] used a lot of its ideas for inspiration! I haven't used LINQ, but in Ecto, there are so many useful constructs for composing queries. If you get a stinker of a query, you have multiple escape hatches such as fragments [1] or just writing the queries directly as needed [2].
For beginners, the Elixir language constructs can be a little clunky, but once you get it, it's so productive and I miss that productivity when doing more advanced queries in other languages.
[0]: https://hexdocs.pm/ecto/Ecto.Query.html https://hexdocs.pm/ecto/Ecto.Query.html
[1]: https://hexdocs.pm/ecto/Ecto.Query.html#module-fragments https://hexdocs.pm/ecto/Ecto.Query.html#module-fragments
[2]: https://hexdocs.pm/ecto_sql/Ecto.Adapters.SQL.html#query/4 https://hexdocs.pm/ecto_sql/Ecto.Adapters.SQL.html#query/4