Problems with Refresh after ApplyUpdates.

Discussion of open issues, suggestions and bugs regarding usage of dbExpress drivers for SQL Server in Delphi and C++Builder
Post Reply
HK
Posts: 12
Joined: Tue 14 Nov 2006 13:30

Problems with Refresh after ApplyUpdates.

Post by HK » Tue 14 Nov 2006 13:40

I run this code :

with THKClientDataSet(
FHKDataSource.DataSet) do
begin
Append;
FieldByName(FDataField.FieldName).AsInteger := HKCDSOrigem.Fieldbyname('CHAVE').AsInteger;
Fieldbyname('SITUACAO').AsInteger := 1;
FieldByName('DTINICIO').AsDateTime := now
FieldByName('DTSITUACAO').AsDateTime := now;
Post;
ApplyUpdates(0);
Refresh;

end;

If I use my Firebird driver, it works great.
But when I change to my Corelab MSSQL dbexpress driver, I receive that message:
"cdsXXX: Must apply updates before refreshing data".
Note that I call ApplyUpdates. Very Weird .... :?

I´m using Delphi 7 , with Corelab MS SQL Server dbexpress driver 3.10.6

HK
Posts: 12
Joined: Tue 14 Nov 2006 13:30

Post by HK » Wed 15 Nov 2006 11:31

I found the problem.

The problem is that CoreLab do not "clean" a space or a enter in SQL command. Table Name is 'ENTIDADE' and the corelab pass to SQL Server like that : ' ENTIDADE' .

There a way that CoreLab correct this ISSUE?

Jackson
Posts: 512
Joined: Thu 26 Jan 2006 10:06

Post by Jackson » Wed 15 Nov 2006 12:32

We couldn't reproduce the problem.
Please send us (evgeniym*crlab*com) a complete small test project to reproduce the problem;
it is desirable to use Northwind or Master schema objects, otherwise include definition of your own database objects;
don't use third party components.

Also supply us with exact version of Microsoft SQL Server and OLE DB provider that you use.
You can see it in version info of SQLOLEDB.DLL and SQLNCLI.DLL.

Post Reply