Quantcast
Channel: Xojo Programming Forum - Latest topics
Viewing all articles
Browse latest Browse all 3877

Mac OSX ODBC to MSSQL

$
0
0

Hi to all,
I would like to connect to a Microsoft sql server via Xojo ODBC driver (I don’t want to use paid plugins) from my Mac. This is my situation: Xojo web application, Mac os 12.4.7, Xojo 2024R1, Ms-SQL Server 2019. I installed the Microsoft odbc drivers (https://learn.microsoft.com/it-it/sql/connect/odbc/linux- mac/install-microsoft-odbc-driver-sql-server-macos?view=sql-server-ver16) everything is ok, if from the command line I try to connect to the sql server (sqlcmd -S 192.168.1.40 -U sa -P XXXXX -C) everything works (Exit:[SQL_SUCCESS]). Now I’m trying to connect via Xojo, the code and connection string I’m using is this:

Var myDatabase as new ODBCDatabase
myDatabase.DataSource = “Driver={ODBC Driver 18 for SQL Server};Server=192.168.1.40;Database=xojo_db;UID=sa;PWD=XXXXX;Encrypt=No;TrustServerCertificate=Yes;”
myDatabase.Connect

When I run the application the browser opens and shows the popup message “Connection problem. We are having trouble communicating with the server. Please wait a moment while we attempt to reconnect.”, the Xojo IDE closes the runtime execution and only the source mask remains without any error messages.

Does anyone have any suggestions on how to understand where the problem might be? Maybe in the connection string?

Thank you

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 3877

Trending Articles