TOracleDataset and substitution variables

Betz

Member²
Hello,

I'm using DOA 4.06 and Delphi 7.

My SQL in the TOracleDataset is
select v.* from RMA.V_RMA v
where v.MT_Final_7S_date is null
or :all
:ORDER
where :all and :Order are substitution variables.

The Dataset works fine as long as I only replace the variables by the delphi Program.
The problem comes up when I use QBE (by Oraclenavigator). When the QBE is executed, the substitution variables are directly replaced by the latest values for this variables
(e.g.
...
or 1=1
order by RMA_NO)
Any further change of the previous substitution variables are not possible, because the SQL does no longer show the :all and :ORDER variables.
What can I do that the substitution variabes stay in the SQL when using QBE?

Best regards

Betzenb
 
Unfortunately the QBE criteria can only be applied when substitution variables are replaced, since they can change the meaning of the SQL statement. You will need to use bind variables instead.

When QBE is cancelled, the original SQL and substitution variables will be restored, so that you can apply new values for substitution variables.
 
Back
Top