and finally my db manager where I'm querying: ```f...
# anko
and finally my db manager where I'm querying:
Copy code
fun getCount(): Int {
        var listDbNodes = mutableListOf<DbNodeModel>()
        dbHelper.use {
            select(NodeTable.TABLE_NAME).parseList(object: MapRowParser<List<DbNodeModel>> {
                override fun parseRow(columns: Map<String, Any?>): List<DbNodeModel> {

                   val routeID = columns.getValue(NodeTable.ROUTE_ID)
                   val siteId = columns.getValue(NodeTable.SITE_ID)
                   val activityId = columns.getValue(NodeTable.ACTIVITY_ID)
                   val equipmentId = columns.getValue(NodeTable.EQUIPMENT_ID)
                   val barcode = columns.getValue(NodeTable.BARCODE)
                   val scannedOn = columns.getValue(NodeTable.SCANNED_ON)
                   val scannedBy = columns.getValue(NodeTable.SCANNED_BY)
                   val deviceImei = columns.getValue(NodeTable.DEVICE_IMEI)

                    val dbNode = DbNodeModel(routeID, siteId, activityId,                   <----this is where I'm getting cast error
                            equipmentId, barcode, scannedOn, scannedBy, deviceImei)

                    return listDbNodes

        return listDbNodes.size
I know it's a late answer, but what are your selected columns? Is it possible to state all columns by simply not providing this argument?