Hi there.
I’m using the new Kotlin stuff in 7.2, and I’ve hit on a snag.
I have a piece of JPQL to retrieve the highest value in a table field:
//language=EQL
const val GET_HIGHEST_SEQUENCE_NUMBER_JPQL =
"""select max(t.sequenceNumber)
from kipper_TaskTemplate t
where t.processTemplate = :processTemplate"""
t.sequenceNumber should be an integer value, but I’m not sure how to retrieve it in Kotlin:
val highestSequenceNumber = dataManager.loadValue(GET_HIGHEST_SEQUENCE_NUMBER_JPQL, Int::class)
.parameter("processTemplate", processTemplate)
.one()
The second parameter for the loadValue
call – what should that be if I’m returning an Int?