I use Mybatis get postgreDB sequences
The import_order_seq set
"Increment By" 1
"Max value" 9999
"Min valu" 1
"Cache Value" 20
the Mybatis xml
<select id="getSequence" resultType = "java.lang.String">
select import_order_seq.nextval from dual
</select>
The java code
String x = xxxx.getSequence()
The problem is when I execute the java code x is 21 ,41,61,81.....,
not 1,2,3,4....
How can I let x is 1,2,3,4....??