View and a DBGrid - Records lost after Update

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
so-photo
Posts: 5
Joined: Thu 26 Apr 2018 11:11

View and a DBGrid - Records lost after Update

Post by so-photo » Tue 05 Jun 2018 17:06

Hi

I have a table in a DBGrid. If I now send Updated with calculations to the server and then do a refresh record I have the record of above or below standing in the place. Only deactivating and activating brings back the correct display.

Fetchall, CursorUpdate, DMLRefresh, FullRefresh, RemoveOnRefresh tested in all logical combinations brings me but no solution.

Someone already had something?

Delphi XE7, latest sdac 8.0.5, MS Server 14.

Thanks
Stevie

Stellar
Devart Team
Posts: 496
Joined: Tue 03 Oct 2017 11:00

Re: View and a DBGrid - Records lost after Update

Post by Stellar » Thu 07 Jun 2018 09:48

If no index was set for TMSTable/TMSQuery, then after changing, the record in the client DataSet will remain in the same position. If, after changing the record, you will update the Dataset data, for example by calling the Refresh method, then the server can return data where the changed record may take a different position. Unfortunately, we cannot influence the server behavior, you can read more information about this behavior in MS SQL Server documentation.

Post Reply