No commit activity in last 3 years
No release in over 3 years
Enables SQLite database access from a DRb server.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 0.2, >= 0.2.10
~> 0.9, >= 0.9.4
~> 1.4, >= 1.4.1
 Project Readme

Introducing the drb_sqlite gem

Setting up the server

installation

gem install sqlite_server2018

require 'sqlite_server2018'

SQLiteServer2018.new(host: '127.0.0.1').start

Using the client

require 'drb_sqlite'

# Open a database
db = DRbSQLite.new 'test.db'

# Create a database
sql=<<-SQL
  create table numbers (
    name varchar(30),
    val int
  );
SQL
rows = db.execute sql

# Execute a few inserts
{
  "one" => 1,
  "two" => 2,
}.each do |pair|
  db.execute "insert into numbers values ( ?, ? )", pair
end

# Find a few rows
db.execute( "select * from numbers" ) do |row|
  p row
end

Observed:

["one", 1]
["two", 2]

Resources

sqlite sqlite3 gem drb_sqlite3 server sqlite_server2017 sql