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 66
66:         def select_limit_sql(sql)
67:           if l = @opts[:limit]
68:             if l == 1
69:               sql << FETCH_FIRST_ROW_ONLY
70:             elsif l > 1
71:               sql << FETCH_FIRST
72:               literal_append(sql, l)
73:               sql << ROWS_ONLY
74:             end
75:           end
76:         end

[Source]

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

[Validate]