Class Sequel::JDBC::AS400::Dataset
In: lib/sequel/adapters/jdbc/as400.rb
Parent: JDBC::Dataset

Dataset class for AS400 datasets accessed via JDBC.

Methods

Included Modules

EmulateOffsetWithRowNumber

Constants

WILDCARD = Sequel::LiteralString.new('*').freeze
FETCH_FIRST_ROW_ONLY = " FETCH FIRST ROW ONLY".freeze
FETCH_FIRST = " FETCH FIRST ".freeze
ROWS_ONLY = " ROWS ONLY".freeze

Public Instance methods

Modify the sql to limit the number of rows returned

[Source]

    # File lib/sequel/adapters/jdbc/as400.rb, line 64
64:         def select_limit_sql(sql)
65:           if l = @opts[:limit]
66:             if l == 1
67:               sql << FETCH_FIRST_ROW_ONLY
68:             elsif l > 1
69:               sql << FETCH_FIRST
70:               literal_append(sql, l)
71:               sql << ROWS_ONLY
72:             end
73:           end
74:         end

[Source]

    # File lib/sequel/adapters/jdbc/as400.rb, line 76
76:         def supports_window_functions?
77:           true
78:         end

[Validate]