Module bus.pager

Class SqlServer2012RowBounds

All Implemented Interfaces:
Dialect

public class SqlServer2012RowBounds extends SqlServerRowBounds
SQL Server 2012 dialect for pagination based on RowBounds. This class provides SQL Server 2012-specific SQL generation for pagination using `OFFSET ... ROWS FETCH NEXT ... ROWS ONLY` syntax.
Since:
Java 17+
Author:
Kimi Liu
  • Constructor Details

    • SqlServer2012RowBounds

      public SqlServer2012RowBounds()
  • Method Details

    • getPageSql

      public String getPageSql(String sql, org.apache.ibatis.session.RowBounds rowBounds, org.apache.ibatis.cache.CacheKey pageKey)
      Generates the SQL Server 2012-specific pagination SQL using RowBounds. It appends `OFFSET ? ROWS FETCH NEXT ? ROWS ONLY` to the original SQL.
      Overrides:
      getPageSql in class SqlServerRowBounds
      Parameters:
      sql - the original SQL string
      rowBounds - the RowBounds object containing offset and limit
      pageKey - the CacheKey for the paginated query
      Returns:
      the SQL Server 2012-specific paginated SQL string