Class: SQLParser::Statement::Update

Inherits:
Node
  • Object
show all
Defined in:
lib/sql-parser/statement.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#accept, #to_sql

Constructor Details

#initialize(table_reference, update_column_list, where_clause = nil) ⇒ Update

Returns a new instance of Update.



45
46
47
48
49
# File 'lib/sql-parser/statement.rb', line 45

def initialize(table_reference, update_column_list, where_clause = nil)
  @table_reference = table_reference
  @update_column_list = update_column_list
  @where_clause = where_clause
end

Instance Attribute Details

#table_referenceObject (readonly)

Returns the value of attribute table_reference.



51
52
53
# File 'lib/sql-parser/statement.rb', line 51

def table_reference
  @table_reference
end

#update_column_listObject (readonly)

Returns the value of attribute update_column_list.



52
53
54
# File 'lib/sql-parser/statement.rb', line 52

def update_column_list
  @update_column_list
end

#where_clauseObject (readonly)

Returns the value of attribute where_clause.



53
54
55
# File 'lib/sql-parser/statement.rb', line 53

def where_clause
  @where_clause
end