Unable to connect to MSSQL Server 2008 R2 database

Trying to connect to MSSQL Server Database 2008 R2 (Enterprise Edition-64bit) using SQL Authentication via Insert Database option in Xojo menu but hit with a message box that “Xojo could not connect to the database”. I tried via code also and hit with a following message “SQL Server Plugin not supported on this platform”. I am using Xojo version 2014 Release 2.1 in Mac OS X Yosemite (10.10.1) - MacBookPro. The MSSQL Server 2008 R2 is running in Windows 8 Enterprise Edition - 64bit. I can able to connect to this database from the same MacBookPro using RazorSQL client. Need help on this issue.

you could try MBS SQL Plugin as an alternative.
http://www.monkeybreadsoftware.de/xojo/plugin-sql.shtml

mssql server plugin works only on windows platform
you must use mbs plugin no alternative !

You could try changing the db type to ODBC. The MSSQL plugin requires the Microsoft SQL Native Client to be installed.

Following up Wayne’s comment, I’ve used Actual’s SQL ODB Driver with excellent results. You only need this for the Mac side.

Thanks all for your help. MBS SQL Plugin in Windows only worked for MS SQL Server 2008 R2. On the OS X Yosemite, MBS Plugin also not working for the above mentioned server. Following is the code snippet used for connecting to the DB Server.

Dim con As New SQLConnectionMBS

con.Option(“OLEDBProvider”)=“SQLNCLI10”
con.Connect(“192.160.1.210\Win8sk38S8@TestDB”,“admin”,“password”,SQLConnectionMBS.kSQLServerClient)
con.Scrollable=false

==> Win8sk38S8 is the MS SQL Server instance name.
==> TestDB is the database i am accessing it.

Because your trying to use a windows driver on OS X.

for OSX, please review what Tanner provided:

Christian has a way to connect from OSX to SQLServer where you do not need to buy an ODBC driver.
https://www.mbsplugins.de/archive/2014-07-01/Tip_of_the_day_Connect_to_MS_S

He has an example project:
Examples/SQL/SQLDatabaseMBS Microsoft SQL via ODBC on Mac.xojo_binary_project

And he has the free tds driver for download here (FreeTDS.dmg):
http://www.monkeybreadsoftware.de/xojo/download/plugin/Libs/

I remember that Norman pointed out once, that there were issues with early versions of FreeTDS, but the current version is fine, AFAIK.

if something does not work with our plugin, please tell me.
Maybe you missed to set a required option.

[quote=145988:@Christian Schmitz]if something does not work with our plugin, please tell me.
Maybe you missed to set a required option.[/quote]
The solution with Freetds you are writing about in your blog works very well for me.

Norman pointed out, that Freetds did not support everything, at least in earlier versions. See conversation here:
https://forum.xojo.com/15525-mssqlserverdatabase-plugin-on-linux/p1#p127527

There is no issue with the MBS plugin.

Freetds protocol version prior to 7.0 did not support SQL server extended data types, like varchar. Current version does.

does SQLDatabaseMBS require a license?

Yes it does, it appears that it’s 149.00 USD…

Still better to have one license for the developer instead of an odbc license for each customer.

and if you use SQLConnectionMBS, you don’t need the Xojo Database Server License.
Of course if you have one or a Pro license (which you can get discounted currently), you can use SQLDatabaseMBS class.