Whatever your opinion of Mnesia is, has anyone used joins via qlc - query list comprehension - in an Elixir form?
It appears based on this thread that qlc operates on Erlang style list comprehensions instead of Elixir style. I noticed this Qlc library but this is also Erlang style.
Just curious if anyone has tried this out in Elixir and curious as to the build steps. Without being able to join tables here with qlc wondering how people are joining tables in Mnesia land…
Here’s some erlang qlc from the mnesia chapter of Programming Erlang
do(qlc:q([X#shop.item || X <- mnesia:table(shop),
X#shop.quantity < 250,
Y <- mnesia:table(cost),
X#shop.item =:= Y#cost.name,
Y#cost.price < 2
])).
and the equivalent SQL
SELECT shop.item, shop.quantity, cost.name, cost.price
FROM shop, cost
WHERE shop.item = cost.name
AND cost.price < 2
AND shop.quantity < 250