We are running into an error when trying to run the export sql command while connected to a secondary host. In this case hana108 is the primary and hana109 is the secondary and the directory we are exporting to is shared between hosts:
hdbsql=> \c -i 00 -n hana108:30015;hana109:30015;hana110:30015 -u CC41 -p ********
Connected to A01@hana108:30015
hdbsql A01=> export "CC41"."*" AS CSV INTO '/usr/sap/A01/HDB00/work' WITH REPLACE THREADS 4
0 rows affected (4956.225 msec)
hdbsql A01=> \di
Connection closed
hdbsql=> \c -i 00 -n hana109:30015;hana108:30015;hana110:30015 -u CC41 -p ********
Connected to A01@hana108:30015
hdbsql A01=> export "CC41"."*" AS CSV INTO '/usr/sap/A01/HDB00/work' WITH REPLACE THREADS 4
* 8: invalid argument: No objects to export found in given schema(s) SQLSTATE: HY000
We also see this error when issuing the command in JDBC when specifying all host names in the connect string.