Support Distinct Count

Commit includes changes for below issues
phoenix#276 (Support type conversion to Int/Long from VARBINARY)
phoenix#8 (Support Distinct Count)