How can I detect if the statement is a select or non select?

The stable tester's forum for ZeosLib 7.0.x series

Report problems concerning our Delphi 2009+ version and new Zeoslib 7.0 features here.
Post Reply
snorkel12068
Fresh Boarder
Fresh Boarder
Posts: 1
Joined: 06.03.2013, 16:51

How can I detect if the statement is a select or non select?

Post by snorkel12068 »

Hi,
Is there a way in Zeos 7 to detect if the statement is a select or non select?
reason I ask is I am writing a small query editor and I would like to be able to use a single button to execute whatever the user selects.

I am running Lazarus 1.0.6 and FPC 2.6.2 and latest SVN version of Zeos

Thanks,

Snorkel
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

Use Open and intercept the 'no dataset' error?
Search for 'select' in the sql statement?

Inside some dbc drivers we use the database client library to check this. But then you're already passing the query to the database library, something you probabl don't want to do yourself when using a component set as zeoslib that tries to be as db independent as possible.

Mark
Image
Post Reply