MS SQL Server connection

Here are the steps I followed to get my apps up and working in connection to Microsoft SQL Server again:

  • Install ODBC driver for SQL Server version 17
  • Convert classes from MSSQLServer to ODBCDatabase
  • Change all of the NEW commands from NEW MSSQLServer to NEW ODBCDatabase* In my connection methods, set the DriverName to use ODBC 17. ( mDB.DataSource = “Driver={ODBC Driver 17 for SQL Server};Server=” + App.cServer + “;Database=” + App.cDatabase + “;UID=” + App.cUser + “;PWD=MySecretDBPassword;”
    )
  • Change all prepare objects from MSSQLServerPreparedStatement to be ODBCPreparedStatement
  • Change all bindings from MSSQL bindings to ODBC bindings (example: ODBCPreparedStatement.ODBC_TYPE_STRING)

That should take care of 99% of the issues.

3 Likes