TMsLoader causes error

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
jmuehlenhoff
Posts: 36
Joined: Fri 30 Apr 2010 11:25

TMsLoader causes error

Post by jmuehlenhoff » Wed 22 Feb 2012 10:39

Hi,

when I try to use a TMsLoader the SQL server sends back an error:

"table/view either does not exist or contains errors"

This happens on permanent and temporary tables.

Delphi version is D2007 and MSSQL is 2008 R2.

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Thu 23 Feb 2012 13:33

Hello,

Please specify your SDAC version, and also show the Delphi code which causes this error.

jmuehlenhoff
Posts: 36
Joined: Fri 30 Apr 2010 11:25

Post by jmuehlenhoff » Fri 24 Feb 2012 10:13

SDAC version is 6.1.4.

I have to correct myself. It does work on permanent tables, but doesn't work on temporary ones.

I have one TMSConnection, one TMSQuery and one TMSLoader on the form.

So both query and loader have the same connection.

The query has this SQL code:

Code: Select all

SELECT TOP 0 * INTO #TMP_ADR FROM ADR
The loader has its TableName set to: #TMP_ADR

Then the only Delphi code I run is:

Code: Select all

MSQuery1.ExecSQL;
MSLoader1.LoadFromDataSet(SourceDataSet);

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Fri 24 Feb 2012 14:25

Hello,

We create a new session to request the IOpenRowset interface for fast data loading into a table, and therefore TMSLoader cannot work with temporare tables.

Post Reply