public
Created

  • Download Gist
gistfile1.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
module Shogun
module Once
class OnceRecord < Sequel::Model
Sequel.extension :pg_array
DB.extend Sequel::Postgres::PGArray::DatabaseMethods
unrestrict_primary_key
end
 
def self.ever(*arguments, &blk)
OnceRecord.create(signature: signature(arguments), arguments: arguments.pg_array)
end
 
def self.signature(*arguments)
signature = arguments.join(' ')
end
end
end

ERROR: missing dimension value at character 73
STATEMENT: INSERT INTO "once_records" ("signature", "arguments") VALUES ('sample', '["sample"]') RETURNING *

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.