Advance query: support for exporting query data