Method: Mongify::Configuration#sql_connection

Defined in:
lib/mongify/configuration.rb

#sql_connection(options = {}, &block) ⇒ Object

Returns a sql_connection If a block is given, it will be executed on the connection For more information, see Database::SqlConnection



32
33
34
35
36
# File 'lib/mongify/configuration.rb', line 32

def sql_connection(options={}, &block)
  @sql_connection ||= Mongify::Database::SqlConnection.new(options)
  @sql_connection.instance_exec(&block) if block_given?
  @sql_connection
end