rantav/hector — Issue #353: How to use serializers in hector api to get the column value of different data type from the passing argument's datatype in IndexedSlicesQuery?
Author: rvijayakumar82
Created: 2011-11-24 07:01:15+00:00
State: open

Hi,

I have a scenario as mentioned below and I decided to use IndexedSlicesQuery.

Scenario:
--------------
Retrieve the lastnames for the given age.

In this scenario the 'age' column is IndexedColumn and the data type is Integer where as the lastname column is of datatype 'String'.

Using hector api's IndexedSlicesQuery requires keyname_serializer,columnname_serializer and value_serializer. As I looked into the api implementation, the 'value_serializer' is the one which is used to convet the value passed in for the 'addEqualsExpression' method in IndexedSlicesQuery as well as the value returned from the selected columns.

How can we use same serializer for different data types as mentioned in the above scenario?
Also, how can we use single serializer if we retrieving more than one column if the columns are of different datatype?