Reply to topic

Kexi SQL Query

User avatar GJim
Registered Member
Posts
2
Karma
0

Kexi SQL Query

Fri Apr 10, 2015 9:55 am
New to Kexi, long-time user of MS-Access and other database applications.

What is wrong with the following SQL Query?

~~~

INSERT INTO exhibitor_export (export_company)
SELECT company
FROM exhibitors;

~~~

'Check Query' tells me that the query is incorrect, that 'INSERT' is a reserved keyword.

I know 'INSERT' is a reserved keyword - but the SQL syntax looks correct to me.

The table names, and field names, are correct.

My final query will be much more complicated than this - but can't even get this simple code to run.

AtDhVaAnNkCsE

G-Jim c):{-
User avatar jstaniek
Moderator
Posts
929
Karma
2
OS

Re: Kexi SQL Query

Fri Apr 10, 2015 10:21 am
Hi GJim,
The SQL view actually only accepts SELECT queries.

Under the mask, unlike other tools, it is not passing the entered query statements to the db backend blindly. Instead it parses the query against internally-standardized KEXISQL SQL variant, what helps to display the query design graphically. When needed, the parsed query is used to generate native query statements suitable for given db backend. In the future one of the backends can be even a flat CSV file - we won't generate SQL in this case.

So our aim is to have a kind of superset of ODBC.

This will be extended in the future to functional queries (INSERT, UPDATE, ...).

Since any backend can be connected with external db admin tools, you can do it and run the INSERT/UPDATE/etc. queries there. Unless you're calling ALTER TABLE deeply changing table structure, Kexi is ok with that (just reopen the table/form view that uses the data to see the updates).

Hope this helps.


Best regards,
Jarosław Staniek
Image

KEXI - Open Source Visual DB Apps Builder
• Request feature or fix for KEXI here
May I help you? Please mention your app's version and OS when asking for help
User avatar GJim
Registered Member
Posts
2
Karma
0

Re: Kexi SQL Query

Fri Apr 10, 2015 1:03 pm
Thanks for the information, Jaroslaw.

Do you have a backend that you would recommend?

G-Jim c):{-
User avatar jstaniek
Moderator
Posts
929
Karma
2
OS

Re: Kexi SQL Query

Fri Apr 10, 2015 1:12 pm
GJim wrote:Do you have a backend that you would recommend?

PostgreSQL or MySQL for multi-user solutions (pick any ofthe two that suits you best), SQLite for single-user cases (it's solid storage too).

Sybase/MSSQL and xBase/dBase backends are supported too. These have fewer users it seems, what translates to smaller group of testers I guess...

We don't plan more, at least it's too hard to offer and maintain more in spare time.

J.


Best regards,
Jarosław Staniek
Image

KEXI - Open Source Visual DB Apps Builder
• Request feature or fix for KEXI here
May I help you? Please mention your app's version and OS when asking for help

 
Reply to topic

Bookmarks



Who is online

Registered users: Baidu [Spider], Bing [Bot], BobF, Google [Bot], MSN [Bot], Zeikcied