<JDBI: querying a string column with kotlin> I hav...
# stackoverflow
u
JDBI: querying a string column with kotlin I have a column title in a SQL table myTable. Using Kotlin and JDBI, how would I go about getting all the distinct entries in this table? This is what I have tried so far: val jdbi = Jdbi.create("...url", "...user", "...password") fun getTitles(): List = jdbi.withHandleUnchecked { handle -> handle.createQuery("select distinct(title) from myTable;") .mapTo(String.javaClass) .list() However, this gives me the following exception: A bean, Companion was mapped which...