Module: Sequel::IBMDB::Dataset::CallableStatementMethods

Defined in:
lib/sequel/adapters/ibmdb.rb

Instance Method Summary collapse

Instance Method Details

#subselect_sql_append(sql, ds) ⇒ Object

Extend given dataset with this module so subselects inside subselects in prepared statements work.



379
380
381
382
383
384
385
# File 'lib/sequel/adapters/ibmdb.rb', line 379

def subselect_sql_append(sql, ds)
  ps = ds.to_prepared_statement(:select).clone(:append_sql=>sql)
  ps.extend(CallableStatementMethods)
  ps = ps.bind(@opts[:bind_vars]) if @opts[:bind_vars]
  ps.prepared_args = prepared_args
  ps.prepared_sql
end