Skip to content

Instantly share code, notes, and snippets.

@rozap
Forked from Linicks/gist:29267d895efffdbc644c
Last active August 29, 2015 14:21
Show Gist options
  • Save rozap/e7cb494931dc233de88c to your computer and use it in GitHub Desktop.
Save rozap/e7cb494931dc233de88c to your computer and use it in GitHub Desktop.
def authors(cd) do
#Connect to the database.
conn = RethinkDB.connect([host: "10.0.0.30", port: 28015])
q = case cd do
"create" -> table_create("authors")
"destroy" -> table_drop("authors")
end
|> run(conn)
IO.puts "#{inspect q.data}"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment