September 27th, 2012, 03:16 AM
Delphi & Oracle
Using Delphi 5 or 7 and Oracle 7-8-9.
If you run a script SQL INSERT INTO or UPDATE by SQL Worksheet, it returns also the number of row processed.
Is it possible have this result also run query INSERT INTO and UPDATE by TQuery component (BDE) ?
September 27th, 2012, 12:47 PM
BDE is very old technology, I would certainly suggest changing to either Delphi's direct support components for Oracle if you have an appropriate version or one of the third party component sets.
I have uses DOA from Allround Automations for over a decade and have found it to be wonderful.
If you are already developing against Oracle, I can not see the very reasonable cost being a barrier.
NOTE: I have no financial interest in Allround Automations.
September 27th, 2012, 01:07 PM
I know DOA. But I have to modify an application who is based on BDE and runs for 17 years. So, I am searching a solution on BDE.
However, I am honest If I say I would not know how DOA return the number of processed rows in query INSERT, DELETE.
Originally Posted by clivew
September 27th, 2012, 03:09 PM
If you are dealing with modifying a 17 year old program, I am not sure just what flexibility is available to you.
I am also not sure (how helpful am I?) whether you can get the row count directly in BDE
or in DOA through a simple property.
I would have to check; but I assume you have done that.
I do know that you can achieve it via an Oracle stored procedure by capturing
immediately after the SQL statement.
HTH - Clive
function doDeletes(pass in whatever you need) return integer is
v_deletedCount := -1; -- If you want some failure return value
v_deletedCount := SQL%ROWCOUNT;