when to use exec / echo external script query