zz1433
zz1433

Reputation: 3586

Firebird multiple statements

is there any way to execute multiple statements (none of which will have to return anything) on Firebird? Like importing a SQL file and executing it.

I've been looking for a while and couldn't find anything for this.

Upvotes: 7

Views: 15096

Answers (5)

TPAKTOPA
TPAKTOPA

Reputation: 2682

Execute block is exactly for that purpose. Works in IBExpert too, a simple example :

execute block as
begin
  Update stuff; 
  Delete stuff; 
  Update stuff;
end

Comprehensive guide, with temporary variables and cycles into it: EXECUTE BLOCK

Upvotes: 14

P A V L I K
P A V L I K

Reputation: 11

In IBExpert you can execute multiple commands in single script via Tools->Script Executive (Ctrl+F12)

Upvotes: 1

Ricardo Jassan
Ricardo Jassan

Reputation: 21

You can do it from IBExpert with Script Executive (Menú Tools -> Script Executive). Be sure to connect to the DB you want to run the query's and then at the Script Executive dialog check the "Use current connection" for this to work.

Upvotes: 2

Bobby
Bobby

Reputation: 11576

Shouldn't the normal query-delimiter work? Like:

Update stuff; Delete stuff; Update stuff;

Upvotes: 0

Smot
Smot

Reputation:

You can do this with IBOConsole (download from www.mengoni.it). The SQL window allows you to enter a complete script with the usual ";" delimiter.

Upvotes: 0

Related Questions