FireDAC keeps using native client 11.0 for SQL Server 2000 access [Edit]

With the new Delphi XE5 and FireDAC in possession, I wanted to explore the possiblities of FireDAC, after having worked with ADO for many years. One of the things I tried was connecting to an SQL Server 2000 database, but the following error keeps appearing:

*'[FireDAC][Phys][ODBC][Microsoft][SQL Server Native Client 11.0]SQL Server Native Client 11.0 does not support connections to SQL Server 2000 or earlier versions.'.*

Just to be sure, I downloaded and installed the x64 SQL Server native client which is part of the Feature Pack for Microsoft SQL Server 2005 SP4 (http://www.microsoft.com/en-us/download/details.aspx?id=20101). Just for your information, the x86 and ia64 versions of this driver produce the following error message on my system (Windows 8.1) when started: "This installation package is not supported by this processor type. Contact your product vendor.". But the x64 version managed to install.

However, the most recent version of the SQL Server native client for SQL Server 2000 and 2005 did not solve my problem. Either FireDAC cannot find it, or it keeps persisting to use SQL Server native client 11.0.

Below I have put a small piece of code just to illustrate my way of connecting to the SQL servers:

{code}
function TForm1.getTotalRecords : integer;
var
  connection  : TFDConnection;
  query       : TFDQuery;
begin
  Result := 0;

  connection := TFDConnection.Create(nil);
  query := nil;
  try
    connection.DriverName := 'MSSQL';
    connection.Params.Add('Server=mydbserver');
    connection.Params.Add('Database=mydatabase');
    connection.Params.Add('User_Name=myuser');
    connection.Params.Add('Password=mypassword');
    connection.Connected := true;

    query := TFDQuery.Create(nil);
    query.Connection := connection;
    query.Open('SELECT COUNT(*) FROM [User]');
    query.First;
    if query.Bof and not query.Eof then
    begin
      Result := query.Fields[0].AsInteger;
    end;
  finally
    FreeAndNil(connection);
    FreeAndNil(query);
  end;
end;
{code}

How should I connect to an SQL Server 2000 database using FireDAC in Delphi XE5, on a Windows 8.1 (64 bit) system? Is it even possible, or do I have to resort to other methods?

Edited by: Peter van der Mespel on Dec 30, 2013 12:32 AM
0
Peter
12/30/2013 8:33:04 AM
embarcadero.delphi.firedac 822 articles. 2 followers. Follow

2 Replies
3542 Views

Similar Articles

[PageSpeed] 41

Hello Peter

1) FireDAC uses by default newest version of SQL Native Client. To force FireDAC SQL Server driver to use a specific SQL Server ODBC driver version, you should set TFDPhysMSSQLDriverLink.ODBCDriver to "SQL Server" (MSSQL 2000 ODBC). More about that:
http://docwiki.embarcadero.com/RADStudio/XE5/en/Configuring_Drivers_(FireDAC)
http://docwiki.embarcadero.com/RADStudio/XE5/en/Connect_to_Microsoft_SQL_Server_(FireDAC)

2) For x86 applications you need x86 client libraries. For x64 applications - x64 libraries.

-- 
With best regards,
Dmitry Arefiev / FireDAC Architect
FireDAC - Firebird, SQLite, MySQL, SQL Server, Oracle, PostgreSQL, 
DB2, SQL Anywhere, Access, Informix, ODBC high-speed data access lib
0
Dmitry
12/30/2013 9:44:53 AM
Hello Dmitry,

Thank you very much for your answer, setting the ODBCDriver property of a TFDPhysMSSQLDriverLink instance to "SQL Server" did the trick!

Kind regards,
Peter
0
Peter
12/31/2013 8:25:30 AM
Reply:

Similar Artilces:

How to prevent SQL Native Client from using Server Side Cursor when connecting to MS SQL 2000
Hi. I am now trying to connect to MS SQL 2000 using SQLNCLI10 / SQLNCLI as Provider. I can connect to the database successfully but I observe that the sql native client generates sp_cursoropen, sp_cursorfetch etc even for a very simple select statement embedded in PowerScript. I think this will greatly impact the performance. I have found that the select statement becomes a single statement batch (no more sp_cursoropen etc) in the profiler trace if the database is changed to MS SQL 2008. How can I avoid it ? Add some setting to ProviderString in...

Unable to use SQL Server because ASP.NET version 2.0 Session State is not installed on the SQL server. Please install ASP.NET Session State SQL Server version 2.0 or above.
Can anybody point me in the direction of how to resolve this error, Unable to use SQL Server because ASP.NET version 2.0 Session State is not installed on the SQL server. Please install ASP.NET Session State SQL Server version 2.0 or above. I am running Visusl Studio 2005, SQL Server 2005 Standard, running on WIndows XP Pro. I am trying to use SQL for session state management. I originally ran the following code from the command line prompt, aspnet_regsql.exe -E -ssadd -sstype p This created an ASPState database. I then manually added my default ASP.NET login as a user. In my web.confi...

This version of Microsoft Sql Server Management Studio can only be used to connect to Sql Server 2000 and Sql Server 2005 servers
When I connect SQL Server 2005 to a remote database i get the error: "This version of Microsoft Sql Server Management Studio can only be used to connect to Sql Server 2000 and Sql Server 2005 servers". Can I confirm it is because: the remote db is of SQL Server 2008? There is a soln mentioned in http://forums.asp.net/t/1324047.aspx Did anybody try this (installing 2008 express: http://www.microsoft.com/express/sql/download/)? I am just checking again, whether it will disturb my existing SQL Server installation, in any means...? Though it is mentioned that it will g...

why is it i keep getting an error 40 when trying to config ASP.NET 2.0 to use SQL Server 2000
I'm trying to configure  ASP.NET2.0 Application to use SQL Server 2000  and yes i did make sure all my setup in configuration manager is setup and  the surface area Whenever i ran the REGSQL .EXE CMD it works until i get to  where it suppose to give you a list of data instance to choose from base on ScottGu article  in step 4 I'm running SQLEXPRESS ADVANCE VWD EXPRESS 05 Thanks Hi, The error message above is actually the standard error message that the ADO.NET API returns when it fails to connect to the database. Typically this is caused becaus...

move data from access to sql server 7.0 using sql queries
Hi All, I hope I am at the right place to post this question: How can I move the tables with its data from Access to SQL Server 7.0 using SQL queries. Later I might put everything in the store procedure and have a third party running the store-procedure to do it by itself. Please advice what should I do first? Do I create new tables in the s SQL Server 7 or can I move the data and create the tables at the same time?..Thank you. You can do this using DTS from your SQL server.  You can create the package, and even make it recurring if you so choose. This is a link describing DTS f...

ASP.Net application developed using SQL Server 2000 can't use SQL Server 2005
Hi,If an application written in ASP.Net that uses SQL Server 2000 can have certain features that will not work on SQL Server 2005?There is an application written in ASP.Net with SQL Server 2000 which I need to convert to SQL Server 2005 but the original developer says it uses certain SQL Server 2000 specific features and won't work directly on SQL Server 2005 without modifying code. Are there any such features? Thanks  According to the official "Discontinued Database Engine Functionality In SQL Server 2005"-document on MSDN, the only Transact-SQL statement that has ...

FireDAC Client/Server for RAD Studio XE5 Professional MS SQL Server Driver
Hello, I have purchased the RAD Studio XE5 Professional Edition and the add-on : FireDAC Client/Server for RAD Studio XE5 Professional. I am attempting to create a simple project : File\New\FireMonkey Mobile Application - Delphi. Confirm the blank application template. Now for the FireDAC components ... I simply add a TFDConnection object to the blank form and the "FDConnection1" is created successfully. I right mouse click and choose "Connection Editor..." from the drop down list. I attempt to select the MS SQL Server driver ID, but it is not available ...

How to setup SQL Server 11.0.3.3 to use 2.0 GB of RAM?
I'm new to Sybase and I will install a SQL Server 11.0.3.3 on a Compaq Proliant ML570 server with 4 Pentium III Xeon 700 processors and 2.5 GB of RAM. The server's operating system is Windows NT 4.0. I'm going to set the Sybase SQL Server to use 2.0 GB of RAM and I heard that the SQL Server doesn't allocate this portion of memory automatically. Is it true? If so, what do I have to do to set the SQL Server to use 2.0 GB of RAM ? Thanks in advance. Vagner First of all I don't think you'll get to use the full 2GB of RAM. You could probably get about 1.8 ...

SQL Server 2000 and SQL Server 2005 Express Edition
Hi,Can SQL Server 2000 and SQL Server 2005 Express Edition installed in a same machine. Will there be any conflict?Regards,Swami Sure they can exists on the same machine. Generally speaking there won't be conflict. The only conflict I have encountered came with SQL2000 named instance: after install SQL2005, the anonymous service on UPD 1434 port (used by SQL2000 to find out named instance) may fail to start, if the "SQL Server Brower" service is not started; so connection may fail to find out SQL2000 named instance. In this case you can just start the "SQL Server Brower" ser...

SQL Anywhere 5.0 and SQL Server 11.0
Hi, we have the folowing problem in my company. There is a SYBASE version 11.0.3 installation by one of our customers. My company which is a producing financial software would like to install there Sybase SQL Anywhere (version 5.5.00) as database for our programs. Is it possible to have these two databases on one server (Netware or Windows NT) ? It is an important case for us. Jakub Yes you can run those two together. Just to push the limit I ran SQL Anywhere, MS SQL Server and Sybase SQL Server all at the same time on my NT Server at home. No complaints from any of the...

FireDac and MS SQL Server [Edit]
Hi, At first I was getting an error that it could not initialize the driver. I installed the native client from here to connect to a 2005 server: http://www.microsoft.com/en-us/download/details.aspx?id=24793 Rebooted, and adjusted the dll names to match the driver dll: sqlncli.dll Now I am getting this error when Testing the Connection in the Data Explorer in the IDE. How do I remedy this, or should I use another method than FireDac? --------------------------- Access violation at address 50588AF1 in module 'vcl190.bpl'. Read of address 00000004. -----------------...

PB6.5 connect MS SQL 2005 using native driver (DBMS=MSS (Msoft) SQL Server 6.0)
Is it possible PB 6.5 using "DBMS=MSS (Msoft) SQL Server 6.0" to connect MS SQL 2005? The existing application is PB6.5 using "DBMS=MSS (Msoft) SQL Server 6.0" to connect MS SQL 2000. It is work fine. John Hi John; AFAIK .. it should work. The only restrictions would be 1) PB 6.5 will not understand SS2005 functionality. You will be restricted to the SS 6.0 (as you are today with SS2000) feature set. 2) The MSS setting connects using the NTDBLIB.dll from MS. I do not believe that this is supplied with SS2005. So you will need to install the SS20...

SQL Server Enterprise 2000 edition Verse Standard edition 2000
Hi there Our ISP hosts our data on SQL Server Enterprise, but I also going to host the databases on my local machine.  As it's just local would Standard edition do?  If I migrate the databases over, will it work? Thanks in advance. Locally you can just use the no deployment Developer edition it is the same with the Enterprise edition but cost a few dollars, so if you have not bought the Standard use the Developer edition.  The Standard or the Developer will be enough for migration later.  Hope this helps.Kind regards,Gift Peddie Okay thanks Gift....

PB 11.5 and SQL Server 2000 or SQL Server 2008
Upgrading from PB 6.5 to PB 11.5 Database is MS SQL Server 2000 compatability level is 80 Has anyone had any issues or know of any issues with PB 11.5 (3050) and MS SQL Server 2000 or MS SQL 2008? We are looking to upgrade from SQL 2000 while upgrading PB 11.5. Originally upgraing SQl Server to SQl Server 2005 but since SQL Server 2008 is out we are exploring to upgrade to the latest SQL Server. Any info will help. Thanks, Tom Rundo ...