edits to query/display scripts