Added query template to data transfert