btclient: fix bug when no files returned by query
btc reduce: add count and unique