fix query and add --ip-address