Try a ColumnListHandler
, and tell it which column to use from your query. You can pass in either the column index or column name to extract. Something like:
List<String> strings = runner.query("SELECT my_col FROM my_table",
new ColumnListHandler<String>(1));
// gets first column
Internally it uses ResultSet#getObject
which returns a String
if the selected column is a string type, so make sure you're not selecting a numeric or date type or something (and if you are, cast or otherwise convert it to a char type in the select query).