querycmd: Fix index create command with -primary flag

Change-Id: I2dc9015d381840b40a81dc2b5d036ee8364f1931
Reviewed-on: http://review.couchbase.org/44013
Reviewed-by: Pratap Chakravarthy <prataprc@couchbase.com>
Reviewed-by: Sarath Lakshman <sarath@couchbase.com>
Tested-by: Sarath Lakshman <sarath@couchbase.com>