TOracleDataSet.SearchRecord Possible Bug

techstar

Member²
Possible Bug.

I have found that the function TOracleDataSet.SearchRecord will compile but will always return false under the following circumstance:

If it is used with TSearchRecordOptions unspecified in the form:

Found := SearchRecord('ename;deptno',VarArrayOf(['A*', 20]),[]);

then the function will compile regardless of whether the uses clause contains OracleData. If compiled without OracleData in the uses clause it will always return false.

However, using an explicit TSearchRecordOptions such as [srForward] will cause the compiler to display an error if OracleData is not in the uses clause.

The result is that you can write a proc using TOracleDataSet.SearchRecord that compiles but does not actually work.

Also, there is no other function of this name in the application.

------------------
Perry Schwartz
TechStar International

[This message has been edited by techstar (edited 08 December 1999).]
 
That means only that you have somewhere your own function with the same name and the same parameters (except the last one which in OracleData is TSearchRecordOptions and could be some other set in your case, because you send empty set the compiler could not distinguish what type this set actually is). It's obvious that in case you set this set in something non empty the compiler generate the error (TSearchRecordOptions declared in OracleData). Point your mouse pointer to the name of the function and click the mouse holding the Ctrl key down and see where it'll send you.
 
Back
Top