Sha256: 72fba80febf6b22c3e768027ed1cf61c89b5a6e1f609ab8061fd207e15dc1a04
Contents?: true
Size: 1.14 KB
Versions: 5
Compression:
Stored size: 1.14 KB
Contents
# frozen_string_literal: true module ActiveRecord module ConnectionAdapters module OracleEnhanced module JDBCQuoting def type_cast(value) case value when ActiveModel::Type::Binary::Data blob = Java::OracleSql::BLOB.createTemporary(@connection.raw_connection, false, Java::OracleSql::BLOB::DURATION_SESSION) blob.setBytes(1, value.to_s.to_java_bytes) blob when Type::OracleEnhanced::Text::Data clob = Java::OracleSql::CLOB.createTemporary(@connection.raw_connection, false, Java::OracleSql::CLOB::DURATION_SESSION) clob.setString(1, value.to_s) clob when Type::OracleEnhanced::NationalCharacterText::Data clob = Java::OracleSql::NCLOB.createTemporary(@connection.raw_connection, false, Java::OracleSql::NCLOB::DURATION_SESSION) clob.setString(1, value.to_s) clob else super end end end end end end module ActiveRecord module ConnectionAdapters module OracleEnhanced module Quoting prepend JDBCQuoting end end end end
Version data entries
5 entries across 5 versions & 1 rubygems