Print Thread
Multi-thread
#3487 05/24/02 02:24 AM
Joined: May 2002
Posts: 4
D
dEnvEr Offline OP
Member
OP Offline
Member
D
Joined: May 2002
Posts: 4
Hi,

I am using TOracleSession, TOracleDataSet version 3.4.6.1 in my delphi 6 project.

To open the query I am using a thread because some queries take really long and I want user to be able to cancel it.

However, when I run the query first time everything is fine but if requery the dataset and run it it generates the error message '..... raised exception class EListError with message

Re: Multi-thread
#3488 05/27/02 09:36 PM
Joined: Aug 1999
Posts: 22,217
Member
Offline
Member
Joined: Aug 1999
Posts: 22,217
Is the dataset connected to a datasource and controls when you open it in a thread?

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

[This message has been edited by mkalter (edited 27 May 2002).]


Marco Kalter
Allround Automations
Re: Multi-thread
#3489 05/29/02 12:49 AM
Joined: May 2002
Posts: 4
D
dEnvEr Offline OP
Member
OP Offline
Member
D
Joined: May 2002
Posts: 4
Yes it is connect to the datasource component.

Thanks for the interest.

Re: Multi-thread
#3490 05/30/02 02:38 PM
Joined: Aug 1999
Posts: 22,217
Member
Offline
Member
Joined: Aug 1999
Posts: 22,217
The dataset/datasource/datacontrols combination is not thread safe. You cannot open a dataset in a thread when it is connected to a datasource. You need to disconnect it from the datasource, open it in a thread, and after the thread is finished, reconnect it to the datasource.

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


Marco Kalter
Allround Automations
Re: Multi-thread
#3491 05/31/02 01:35 AM
Joined: May 2002
Posts: 4
D
dEnvEr Offline OP
Member
OP Offline
Member
D
Joined: May 2002
Posts: 4
Thanks for answer.


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.026s Queries: 13 (0.007s) Memory: 2.5147 MB (Peak: 3.0421 MB) Data Comp: Off Server Time: 2024-05-13 21:05:06 UTC
Valid HTML 5 and Valid CSS