summaryrefslogtreecommitdiff
path: root/db-query.rb
diff options
context:
space:
mode:
Diffstat (limited to 'db-query.rb')
-rwxr-xr-xdb-query.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/db-query.rb b/db-query.rb
new file mode 100755
index 0000000..3a3fa70
--- /dev/null
+++ b/db-query.rb
@@ -0,0 +1,14 @@
+#!/usr/bin/env ruby
+
+require 'sqlite3'
+
+def main
+ db = SQLite3::Database.new ARGV[0]
+ db.execute("select * from power") do |result|
+ puts result.to_s
+ end
+ db.close
+end
+
+
+main