Sha256: 5b915f3570bc7b8fed3eaa2ae870ffb885691f8ef4fc30f513c62536b340fa4c

Contents?: true

Size: 197 Bytes

Versions: 30

Compression:

Stored size: 197 Bytes

Contents

module DbifySqlHelper

  def dbify_sql(sql)
    case ActiveRecord::Base.connection.adapter_name
    when "SQLite"
      sql
    when "PostgreSQL"
      sql.gsub('LIKE', 'ILIKE')
    end
  end

end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
nimbleshop_core-0.0.23 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.21 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.20 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.19 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.17 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.16 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.15 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.14 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.14.rc2 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.14.rc1 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.13 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.12 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.11 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.10 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.9 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.8 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.7 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.5 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.4.beta1 test/support/dbify_sql_helper.rb
nimbleshop_core-0.0.4 test/support/dbify_sql_helper.rb