Subject | Re: [firebird-support] COMMIT and ROLLBACK in SP |
---|---|
Author | Ivan Prenosil |
Post date | 2005-06-16T10:41:11Z |
> I'm mainly concerned with compatibility with other databases that DO allowYou are a bit confused by the term "stored procedure",
> commits and rollbacks and that sometimes it makes sense.
simply because different systems use it to refer to completely
different things.
In Firebird, stored procedure is sql command, and as any other
sql commands it is executed as atomic piece of code inside
transaction, where life cycle on transaction is controlled
by application.
The other databases you are talking about use the term "stored
procedure" to describe "stored script" or "stored macro" or whatever.
> Such as databases that allow a Stored Procedure (SP) to be called by theDo those databases allow calling single statement, like Delete, without
> engine when it initially boots up.
> Or databases that allow you to schedule task which make calls to SP.
using their SP ?
> So just as you "your" reasons for not having commits/rollbacks in SP, otherI am not questioning your need for some feature.
> database developers have found a real need for them...and I agree.
I understand your reasons for wanting to easily run bunch of statements,
including commits/rollbacks, stored somewhere in the database.
The only problem is that you want to implement it in inproper place.
You just want new feature, something like Stored Script.
To slightly paraphrase what this thread was about so far:
"My first sql command I learnt was INSERT, so I use it whenever possible.
Now I have a need to DELETE some rows. How can I use INSERT to delete
rows from table ? Will INSERT ever support deleting ?"
:-)
Ivan