module ViewData::PG::Controls::Row::Put
Public Class Methods
call()
click to toggle source
# File lib/view_data/pg/controls/row/put.rb, line 6 def self.call primary_key = PrimaryKey::UUID.example column_value = Controls::Data.column_value table_name = Table.name session = Session.build session.execute(<<~SQL, [primary_key, column_value]) INSERT INTO #{table_name} (id, some_column) VALUES ($1, $2) SQL session.close primary_key end