Class: MysqlFramework::InCondition
- Inherits:
-
SqlCondition
- Object
- SqlCondition
- MysqlFramework::InCondition
- Defined in:
- lib/mysql_framework/in_condition.rb
Overview
This class is used to represent a Sql IN Condition for a column.
Constant Summary
Constants inherited from SqlCondition
Instance Attribute Summary
Attributes inherited from SqlCondition
Instance Method Summary collapse
-
#to_s ⇒ Object
This method is called to get the condition as a string for a sql prepared statement.
Methods inherited from SqlCondition
Constructor Details
This class inherits a constructor from MysqlFramework::SqlCondition
Instance Method Details
#to_s ⇒ Object
This method is called to get the condition as a string for a sql prepared statement
7 8 9 10 |
# File 'lib/mysql_framework/in_condition.rb', line 7 def to_s params = value.map { |_| '?' } "#{@column} #{@comparison} (#{params.join(', ')})" end |