jschoch / noorm

Helper methods for meh's Amnesia which is mnesia for elixir

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Noorm

** Elixir Helper Methods for Amnesia** major alpha stuff here,

just use NoOrm in your tables

defdatabase Db do
  deftable Rec,[:id,:foo,:stamp],type: :set do
    use NoOrm
  end
end

now you can do stuff like

#return values matching key,val
Db.Rec.all_by_key(:foo,:bar)

add or update based on arbitrary key

record = Db.Rec[id: 1].write!
Db.Rec.aou(:id,[id: 1,foo: "this was updated",stamp: :erlang.now])

About

Helper methods for meh's Amnesia which is mnesia for elixir

License:MIT License


Languages

Language:Elixir 100.0%