Ah, thanks for that feedback.
What you tried didn't work, as COPY TO takes a filename literally even without putting it in quotes, so: How do you use a variable or object property? That's what Tore shows: You put brackets around them. This is called name expression. So the brackets act a bit like quotes, I'd rather say they act like a forced EAVALuation of the expression in brackets.
Notice: You already had aa more concrete question than you posted. It helps very much, if you tell what you tried and post code you tried.
Why extract data to hand it over? A database is there to share data, you share a frontend querying/filtering it as necessary. It's up to you, but just a simple warning: Copying over data into new files creates an ad-hoc data table that has a nondetermined lifetime that may outlive the time it's true. If someone, no matter if developer or technical user, helpdesk or manager needs a list of data, the current situation will not change by the second, but you have a database to persist the current truth there and you should always prefer to get your data directly from it, so what you share is a query configurable with a parameter or an application doing that query and displaying the result. And for that matter you use SQL INTO CURSOR. If that data is then needed for data exchange, exported, then that could be done at that point, but more usual exchange formats are CSV, XML or JSON, maybe even an excel sheet, but very likely not DBF.
Bye, Olaf.
Olaf Doschke Software Engineering