class Sequel::JDBC::AS400::Dataset
Constants
- FETCH_FIRST
- FETCH_FIRST_ROW_ONLY
- ROWS_ONLY
- WILDCARD
Public Instance Methods
select_limit_sql(sql)
click to toggle source
Modify the sql to limit the number of rows returned
# File lib/sequel/jdbc/as400.rb, line 71 def select_limit_sql(sql) # rubocop:disable MethodLength o = @opts[:offset] if o sql << ' OFFSET ' literal_append(sql, o) sql << ' ROWS' end l = @opts[:limit] return unless l if l == 1 sql << ' FETCH FIRST ROW ONLY' elsif l > 1 sql << ' FETCH FIRST ' literal_append(sql, l) sql << ' ROWS ONLY' end end
supports_window_functions?()
click to toggle source
# File lib/sequel/jdbc/as400.rb, line 90 def supports_window_functions? true end