Hive query can be built on the fly