Error about FUpdatingSQLObjIdx when executing simple query

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
upscene

Error about FUpdatingSQLObjIdx when executing simple query

Post by upscene » Tue 31 Jan 2006 11:00

if I do:

select * from mysql.user

and then:

select
count(*)
from
mysql.user

in the same MyQuery, I get an error:
Wrong FUpdatingSQLObjIdx (E:\Developing\Components\CrMyDAC\Source\MyAccess.pas, line 2977)

In between, I do nothing but assigning the SQL, Prepare and Open.

Let me know if you can reproduce this.

--
Martijn Tonies
Upscene Productions

upscene

Post by upscene » Tue 31 Jan 2006 12:13

This seems to happen on prepared queries only.

here's what happens:

- prepare
- open

- change sql
- prepare
- open

However, in unit MyAccess, TCustomMyDataSet.InternalClose doesn't reset the FUpdatingSQLObjIdx item if it's prepared. So far, so good.

Now, change the SQL and call Prepare -> if the FUpdatingSQLObjIdx item had a value of "0", it doesn't get reset, although the SQL has changed.

IMO, this item should be set to "-1" if the SQL changes, so that the component set will attempt to detect the update table and so on.

Can you confirm?

--
Martijn Tonies
Upscene Productions

upscene

Post by upscene » Sun 05 Feb 2006 12:02

Can someone confirm this?
--
Martijn Tonies
Upscene Productions

Ikar
Posts: 1693
Joined: Thu 28 Oct 2004 13:56

Post by Ikar » Tue 07 Feb 2006 12:38

We couldn't reproduce the problem.
Please send us (mydac*crlab*com) a complete small sample to demonstrate it.

Also supply us following information
- Exact version of Delphi
- Exact version of MySQL server and MySQL client. You can see it in Info sheet of TMyConnection Editor

upscene

Post by upscene » Tue 07 Feb 2006 13:00

Test project sent.

--
Martijn Tonies
Upscene Productions

Ikar
Posts: 1693
Joined: Thu 28 Oct 2004 13:56

Post by Ikar » Tue 07 Feb 2006 15:33

Thank you for your sample. It did help us very much.
We reproduced your problem and fixed it. This fix will be included in the next MyDAC build.

Post Reply