Print Thread
Converting OracleDataset to OracleQuery
#1338 12/05/00 10:44 AM
Joined: Jul 2000
Posts: 12
Atlanta, GA USA
D
d4jaj1 Offline OP
Member
OP Offline
Member
D
Joined: Jul 2000
Posts: 12
Atlanta, GA USA
Hello,

I'm trying to convert some code I was using as part of an OracleDataset to OracleQuery for performance reasons. How do I correctly convert this code to the OracleQuery version?

FOR j := ...etc....
if AnsiCompareText(trim(uploadasheets.fields[j + 7].value), trim(GetAnswerKey.Fields[j + 2].value)) = 0 then ..etc...

GetAnswerKey is the OracleDataset I want to convert. I tried FieldName, but I couldn't get it to compile with [j + 2].

Thanks


----------
Jay
Re: Converting OracleDataset to OracleQuery
#1339 12/05/00 06:43 PM
Joined: Aug 1999
Posts: 22,221
Member
Offline
Member
Joined: Aug 1999
Posts: 22,221
The TOracleQuery is not a TDataSet descendant, and it has some different functions to get to the field data. You can use GetAnswerKey.FieldAsString(j + 2) if GetAnswerKey is a TOracleQuery.

------------------
Marco Kalter
Allround Automations


Marco Kalter
Allround Automations

Moderated by  support 

Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.4
(Release build 20200307)
Responsive Width:

PHP: 7.1.33 Page Time: 0.032s Queries: 12 (0.006s) Memory: 2.4991 MB (Peak: 3.0430 MB) Data Comp: Off Server Time: 2024-05-20 11:55:07 UTC
Valid HTML 5 and Valid CSS