Deja Vu Random notes on coding and stuff..

today-i-learned

Today I Learned : PostgreSQL - obtain records that were inserted in the last 5 minutes

select * from my_table where inserted_at > now() - interval '5 minute'...

Today I Learned : Elixir - How to get a map from a struct

Use the Map.from_struct function. struct = %User{first_name: "Jose", last_name: "Valim"} map = Map.form_struct(struct)...