Column fooColumn = source.getColumnByQualifiedLabel("schema.table.foo");
assertNotNull(fooColumn);
Map<Column, TypeConverter<?, ?>> converters = new HashMap<Column, TypeConverter<?, ?>>();
converters.put(fooColumn, new StringToIntegerConverter());
DataContext converted = Converters.addTypeConverter(source, fooColumn,
new StringToIntegerConverter());
// only select "bar" which is not converted
Table table = converted.getDefaultSchema().getTableByName("table");
Query query = converted.query().from(table).select("bar").toQuery();
assertEquals("SELECT table.bar FROM schema.table", query.toSql());
DataSet ds = converted.executeQuery(query);
assertEquals(InMemoryDataSet.class, ds.getClass());
}