Sha256: 6502b5d2edf751e123c3a2b0d1d4241df2979927617088186597fe3fb0faf13b
Contents?: true
Size: 984 Bytes
Versions: 9
Compression:
Stored size: 984 Bytes
Contents
module Rasti module DB module NQL module FilterConditionStrategies module Types class SQLiteArray def self.equal(identifier, values) array = values.map { |value| "\"#{value}\"" }.join(',') {identifier => "[#{array}]"} end def self.not_equal(identifier, values) Sequel.|(*values.map { |value| ~Sequel.like(identifier, "%\"#{value}\"%") }) end def self.like(identifier, values) Sequel.|(*values.map { |value| Sequel.like(identifier, "%#{value}%") }) end def self.include(identifier, values) Sequel.|(*values.map { |value| Sequel.like(identifier, "%\"#{value}\"%") }) end def self.not_include(identifier, values) Sequel.&(*values.map { |value| ~Sequel.like(identifier, "%\"#{value}\"%") }) end end end end end end end
Version data entries
9 entries across 9 versions & 1 rubygems