Class: Webhookdb::DBAdapter::Snowflake::SnowsqlConnection

Inherits:
Connection
  • Object
show all
Includes:
Appydays::Loggable
Defined in:
lib/webhookdb/db_adapter/snowflake.rb

Instance Method Summary collapse

Constructor Details

#initialize(url) ⇒ SnowsqlConnection

Returns a new instance of SnowsqlConnection.



13
14
15
16
# File 'lib/webhookdb/db_adapter/snowflake.rb', line 13

def initialize(url)
  super()
  @url = url
end

Instance Method Details

#execute(sql) ⇒ Object



18
19
20
21
22
23
# File 'lib/webhookdb/db_adapter/snowflake.rb', line 18

def execute(sql, **)
  self.logger.debug("snowflake_exec", statement: sql)
  result = Webhookdb::Snowflake.run_cli(@url, sql, **)
  self.logger.debug("snowflake_exec_result", result:)
  return result
end