add packaged query support