resultConverter

fun resultConverter(json: Json): ResultConverter<*, *>

A read converter for the registered types that decodes payloads with json instead of each class's own, for a query whose payloads are shaped differently - built with jsonb_build_object, or by another service. Register it on that query alone with registerResultConverter.

db.select("benefit").from("veterans")
.registerResultConverter(db.dynamicTypes.resultConverter(snakeCaseJson))
.fetchFields<Benefit>()