How to export ODB schema to SQL text

I have tried to use the online help (I use that term loosely) but it is very vague and not helpful at all sometimes (like this).

I have searched the Internet and can find only references to OpenOffice and a SCRIPT command that is described as available in the SQL tool, but does not work on my LibreOffice 5.0.4 install on Windows or Linux.

So how do I unload an existing ODB database, with structures and data, to an SQL text file?

The same question could be asked about exporting data to CSV from a ODB table.

Does this Q&A help?

Same solution as provided by @frofa

The answer is provided in the following post: export option in libreoffice database is not working

The title is missleading but the answer is the one which you seek.