SQL coding in Base

I’m using LO version on Kubuntu 14.04 LTS.

I’ve just recently moved to Kubuntu from Windows7. I have extensive experience using MS-Access and the SQL structure there.

I have a very extensive SQL statement that I need to run - however I can’t even get a simple statement to work.

Here is simplified version of the SQL code:

INSERT INTO "ExhibitorExport" ( "Export_Company" )

SELECT [Exhibitors].[Company] AS Export_Company

FROM Exhibitors;

When I ‘run’ this code, I get an error message stating:
‘The given command is not a SELECT statement.
Only queries are allowed.’

What is the proper SQL syntax within LO Base?

I have searched this forum for answers, didn’t find anything applicable.


G-Jim c):{-

LO Base uses HSQLDB.

I think you also will need to quote out all of the column names and the table name.


Unfortunately this type of query can be executed only by the Tools SQL menu, then type or paste the SQL.
The only queries that can run by double-clicking on their names are those generating a set of records (SELECT).

A workaround is to use Create Query in SQL View to type and save your SQL in order to copy and paste it when necessary. Alternatively, use macro…


Thanks for the information. Once I used that method, I was able to run my simple query – now, to get the full query running. Again, thanks.

G-Jim c):{-