public class

DB2MainframeSequenceMaxValueIncrementer

extends AbstractSequenceMaxValueIncrementer
java.lang.Object
   ↳ org.springframework.jdbc.support.incrementer.AbstractDataFieldMaxValueIncrementer
     ↳ org.springframework.jdbc.support.incrementer.AbstractSequenceMaxValueIncrementer
       ↳ org.springframework.jdbc.support.incrementer.DB2MainframeSequenceMaxValueIncrementer

Class Overview

DataFieldMaxValueIncrementer that retrieves the next value of a given sequence on DB2/390 or DB2/400. Thanks to Jens Eickmeyer for the suggestion!

Summary

[Expand]
Inherited Fields
From class org.springframework.jdbc.support.incrementer.AbstractDataFieldMaxValueIncrementer
Public Constructors
DB2MainframeSequenceMaxValueIncrementer()
Default constructor for bean property style usage.
DB2MainframeSequenceMaxValueIncrementer(DataSource dataSource, String incrementerName)
Convenience constructor.
Protected Methods
String getSequenceQuery()
Return the database-specific query to use for retrieving a sequence value.
[Expand]
Inherited Methods
From class org.springframework.jdbc.support.incrementer.AbstractSequenceMaxValueIncrementer
From class org.springframework.jdbc.support.incrementer.AbstractDataFieldMaxValueIncrementer
From class java.lang.Object
From interface org.springframework.beans.factory.InitializingBean
From interface org.springframework.jdbc.support.incrementer.DataFieldMaxValueIncrementer

Public Constructors

public DB2MainframeSequenceMaxValueIncrementer ()

Default constructor for bean property style usage.

public DB2MainframeSequenceMaxValueIncrementer (DataSource dataSource, String incrementerName)

Convenience constructor.

Parameters
dataSource the DataSource to use
incrementerName the name of the sequence/table to use

Protected Methods

protected String getSequenceQuery ()

Return the database-specific query to use for retrieving a sequence value.

The provided SQL is supposed to result in a single row with a single column that allows for extracting a long value.