use explicit home directory for query script