Method: Sequel::Dataset#boolean_constant_sql_append
- Defined in:
- lib/sequel/dataset/sql.rb
#boolean_constant_sql_append(sql, constant) ⇒ Object
Append literalization of boolean constant to SQL string.
319 320 321 322 323 324 325 |
# File 'lib/sequel/dataset/sql.rb', line 319 def boolean_constant_sql_append(sql, constant) if (constant == true || constant == false) && !supports_where_true? sql << (constant == true ? '(1 = 1)' : '(1 = 0)') else literal_append(sql, constant) end end |