This is not possible. You can either create csv output or json/xml output, but not both in one query.