you might be added wrong query to below method exportItemsFlexibleSearch, method returns a specified item type therefor you can export only one type(like product, customer etc..) and all attributes which are metioned in your impex header of that type would be exported in to CSV file.
Make sure you have written a query which is returning PK of a type only.
Ex-
INSERT Customer;customerId[unique=true]
"#% impex.exportItemsFlexibleSearch(""SELECT {c:pk} FROM {Customer as C}"");"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.