The export to CSV function is not working for adding layers on the fly (cannot read property 'query' of undefined).
The Layer List allows adding result layer to Attribute Table. But it couldn't use the Export To CSV function from the newly added layer ?!
It would be great to have the export to CSV function available for all tabs inside the Attribute Table widget.