change template and queries