Access to MSSQL SERVER

Hello everyone
xojo

I am trying to make my first connection with MSSQL SERVER 2005
with SQL Server Management Studio I can perfectly access the
the database bdJuarez with the login sa and the password 4016 and the content of
their tables

When trying from xojo with the following code:

  Dim adb As New MSSQLServerDatabase
  
  adb.Host="JIMENA-PC"
  adb.UserName="sa"
  adb.Password="4016"
  adb.DatabaseName="bdJuarez"
  If adb.Connect then
    MsgBox("satisfactory connection to MS SQL SERVER")
  Else
    MsgBox("Error could not connect  "+adb.ErrorMessage)
  End If

shows me the following error:
SQL Server Native Client not installed

I am learning MSSQL Server

Any comments will be greatly appreciated.

Cordially,

Raul Juarez Pulache

The error message is very descriptive. You’ll need to install the SQL Server Native Client. Use your favorite search engine to find the version that supports MS SQL Server 2005. Install it and then try your app again. :slight_smile:

Many thanks
Frederick Roller

download and install SQL Server Native 2005 but same shows me the same error
The operating system is windows 7 ultimate 32-bit, PC name is JIMENA-PC, its ip 192.168.129.3

any additional comments

Very thankful

Raul Juarez Pulache

I believe that the Native Client V.11 still supports SQL Server 2005 (for sure it supports SQL Server 2008).

If you have any control over the version of SQL Server that you are using, I would recommend an upgrade. SQL Server 2005 has been out of support for over a year. If money is a factor, I would suggest the Express version. It is free, 100% compatible with databases from larger releases. It is limited in size and allowed memory, but as a learning tool, it is a good choice. Note that there are subtle differences in the connexion strings with Express. SQL Server 2017 also runs on Linux or on Mac with a Docker container.

I would eliminate Xojo from the issue by connecting to the server via the ODBC manager which will show the drivers installed. Get that working & Xojo won’t have a problem.

Thank you so much
Wayne Golding

In the ODBC Administrator in the System DSN tab
shows the following:

SQL Native Client Driver
SQL Server Driver

and when performing a test in both is satisfactory

also both configured for the database bdJuarez

From xojo to connect to MSSERVER is only via ODBC?

infinite thanks for any comments

Raul Juarez Pulache

No if the driver is installed you should be able to use the MSSQLServerDatabase class.

Thank you so much
Wayne Golding

I do not know why the problem occurs if I have the Native Client installed
and the version is 09.00.1399

The problem will be because it is MS SQL Server version 2005?
Is there a specific native client for this version?

In the test data in ODBC, which performs it successfully
I observe the following and among others:

Data Source Name: Native bdjuarez
Data source Description:
Server:JIMENA-PC
Use Integrated Security : No
Database:bdjuarez
Language:(Default)
DataEncryption:No
Trust Server Certificate:No
Multiple Active Result Sets(MARS): No
Mirror Server:
Translate Character Data:yes
Log Long Runnig Quieres: No
Log Driver Statistics :No
Use Regional Settings:No
Use Ansi Quoted Identifiers: yes
Use ANSI Null, Padding and Warnings:yes

I am infinitely grateful for any additional comments
I need to solve this problem as soon as possible

Raul Juarez Pulache

I seem to recall that native client 11 is required for Xojo. Try installing SQL Server 2012 Express edition on the client machine & check the Native client version.

Infinite Thanks
Wayne Golding

With your help I could solve the problem
Effectively to access MS SQL Server from xojo, is a requirement is the SQL SERVER Native Client 11.0
Download and install Native Client 11.0 and everything works perfectly.
Xojo does not recognize, The native client of the 2005 version

A hug and blessings

Raul Juarez Pulache

Infinite Thanks
Louis Desjardins

Native V.11 client is supported by SQL Server 2005
It helped me a lot to solve the problem

A hug and blessings

Raul Juarez Pulache