Connect to a ODBC DSN installed on a server - delphi

I am developing an application in Delphi 10.2.3 which connects to a Firebird database installed on a machine running Windows 2016 Server. The application also connects to QuickBooks Online using a third party ODBC driver. Since this application must be accessed by 12+ users in my company, it will not be cost effective to purchase and install individual ODBC drivers for each user.
The provider of the ODBC driver has a version which can be installed on a server. Is it possible to configure an ODBC DNS connection on the server which I can access from network clients? If not, can anyone suggest a workaround.

Server vs Workstation ODBC driver usually has to do with licensing not connection method. It is always running on the same machine as the software using the connection.
Web application used by many users running on a server connecting through an ODBC driver = server licensed version of the driver.
User loading data into Excel on their computer through an ODBC driver
= client / workstation licensed driver.
Some databases, for example SQL Server, can do a database link through an ODBC driver. This is linking / exposing another database to querying from a host database server. This would allow you to share one server licensed driver. The clients would connect to the host database.
One such driver is DevArt's ODBC Driver for QuickBooks which has a help topic on creating a linked database and testing it in SQL Server Management Studio / SQL Server: Using in Microsoft SQL Server Management Studio (SSMS). Might not be applicable if each user needs to use different credentials for the QuickBooks connection.

Related

Using ODBC connection with Azure Data Studio

In order to connect to an IBM DB2 database, I am using DBeaver with an ODBC type of connection. But since I found Azure Data Studio very lightweight and portable, I want to ask if there is a way to connect to such databases because all I get is Microsoft SQL Server as connection type.

Hosting RAD Server in IIS. EMS license not found

I have created a 32Bit RAD Server application and I wanted to host it in my local IIS Server. I followed the steps mentioned in here But when I try to call a webservice say http://localhost:8080/emsserver/EMSServer.dll/version I get the following error :
{"error":"Forbidden","description":"EMS license not found. To resolve this issue, install an instance of Interbase with an EMS license and configure emsserver.ini to connect to the licensed instance."}
What could have gone wrong here ?
Is there again another instance of interbase has to be installed ? I had installed the interbase along with the RAD Studio 10.2 set up. The error message also suggests to configure emsserver.ini. What configuration change does it require ?
My Development environment is :RAD Studio 10.2 Enterprise on Win 10 64bit machine. The InterbaseManager is 64-bit. The IBConsole shows Version Interbase 2017 Version 13.0.0.195.
Can someone help me to get this resolved ?
Thanks in advance.
As noted here, for a RAD Server production environment, you cannot use your license for the RAD Studio IDE nor a "normal" InterBase license. Instead, to be able to run RAD Server in production on either IIS or Apache, you must install a RAD Server deployment license into InterBase. Contact Embarcadero directly (or go through your local Embarcadero sales representative) to request your RAD Server deployment license — as of 10.2 Tokyo edition, it is now included at no additional charge for RAD Studio Enterprise or Architect licensees.
Procedurally, depending on your hosting environment, you will add your RAD Server deployment license to InterBase via its License Manager on Windows or via the command line on Linux: /opt/interbase/bin/LicenseManagerLauncher -i Console as discussed here. This presumes you have previously installed InterBase centrally to serve Identity and Access Management (IAM) purposes as well as to record resource data analytics by endpoint (built-in features of RAD Server's RESTful web application framework).
Most importantly, per your question, you must configure each RAD Server instance — via its associated configuration file (EMSSERVER.INI) — to look to this central/common IAM + data analytics database (aka, the "RAD Server Database") hosted in InterBase.
By default, the RAD Server Database is defined within the InterBase file "emsserver.ib" which serves to persist the devices, users, groups and data analytics for all connected RAD Server instances. In turn, the connection parameters required by each RAD Server instance are stored under the [Data] section of the associated EMSSERVER.INI configuration file as detailed hereunder:
[Data]
InstanceName=192.168.0.127/3050
Database=/etc/ems/emsserver.ib
UserName=sysdba
Password=masterkey
SEPassword=
;# SEPassword connects to an encrypted database
Pooled=
;# Set Pooled=0 to disable connection pooled, Pooled=1 to enable (default is 1).
PooledMax=
;# Set PooledMax=10 to limit maximum pooled connection (default is 50).
As exemplified above, the [Data] section within EMSSERVER.INI defines the connection parameters to the central RAD Server Database (powered by InterBase). The connection parameters needed to get started are:
InstanceName: The <IP_Address|Hostname>/<Port_Number> of the InterBase instance hosting the RAD Server Database.
NOTE: Multiple RAD Server instances (i.e., multiple physical installations on separate machines or docker containers as discussed here) can all use the same remote RAD Server Database backend (powered by InterBase) via this InstanceName setting.
Database: The database file (or its alias) served by the InterBase-powered InstanceName pointed to above. On the Windows OS, the default setting for Database is: C:\Users\Public\Documents\Embarcadero\EMS\emsserver.ib. On Linux, the default setting is: /usr/lib/ems/emsserver.ib
UserName and Password represent credentials for the RAD Server instance connecting to the InterBase-powered RAD Server Database (by default, respectively: sysdba and masterkey).
Moving on from there, the SEPassword parameter is used for connecting to an encrypted database. Going further, connection pooling (enabled {=1} by default in the absence of a value) may be explicitly set using the Pooled=1|0. Next, the maximum number of pooled connections from this RAD Server instance to the central/common RAD Server Database is determined by the PooledMax setting (which, otherwise, defaults to 50).
Finally, further information concerning development and deployment of web applications using RAD Server can be found in David I's Complete Guide to Embarcadero RAD Server.

Connecting to Firebird 3

I have installed Firebird 3.0.1 on a PC and on a VM client. I installed Flamerobin on both to test the connection.
I can connect to localhost on both PC and VM using Flamerobin, so I assume the Firebird server is running on both and Flamerobin is installed on both OK
I can connect to the Firebird server on the VM from the PC and open a database Ok
From the VM I can open a database on the PC, but when I try to retrieve the server version on the PC I get an error ISC_Service_attach failed (Unable to complete network request to host).
I have no idea what the problem is given that I can open a database ok, but cannot access any of the utility services.
I am using fbclient.dll 3.0.1.32591 on both VM and PC
If you can achieve network request to server, you need to check firewall setings on server and set fb default port as inbound acceptable. If you would had same problem after that, than you probably need proper fbclient library, for FB3 on client, VM. Hope this helps.

How to connect to a legacy Informix database?

I have to connect my app to a customer's Informix 7.2 legacy database.
From what I was able to find out, in theory there should be a database service running on port 50000. The problem is that I cannot find any database service in the Operative System.
So far I'm only able to use dbaccess and perform queries from the command line.
I would like to use a database driver (such as http://code.google.com/p/ibm-db/) so my app can connect and query the database using a cursor, but since I cannot find any database service, apparently I can't...
Am I missing something here? Are there options I'm not considering?
Is it possible to have an Informix database in which the only interface is dbaccess?
See connection strings for Informix
If you use Python you can look at: Python wiki but I would like to extend it a little.
If you work on Windows and have Client SDK then there should be ODBC driver installed on your machine. There is also Linux and other unix versions of such client software. If you install that you can use ODBC to connect to database. On Windows you can use Active State Python 2.6 with win32 extensions which has odbc module included. On other Python implementations you can use win32 extensions or other ODBC module such as mxODBC.
I work also with Jython where I use both JDBC and ODBC drivers. You can see this "in action" in my SO questions like: Problem with Informix JDBC Money format
BTW, if you want to connect to a remote legacy Informix database using Python from a Mac, pypyodbc-informixcsdk could be your only (free) choice. Check this wiki.
On a Windows box, pyodbc + Informix Client SDK + ODBC do the job nicely.

Visual Studio 2010 and discovery of advantage server error

I installed VS 2010 on a Windows 7 64 bit machine. When I try and connect to an advantage database through the server explorer using the Advanatage OLEDB driver I get a cannot discover advantage database server error. I can connect to the database using the ARC just fine. I was able to connect in VS 2008 just fine. Any ideas on why I can't connect in VS 2010?
If you are trying to connect with "local server", then be sure that your connection string contains "ServerType=ADS_LOCAL_SERVER;". If using Advantage Database Server (remote server), then this link might have some ideas that help. It discusses various ways to provide the IP address and port number if discovery is failing. For example, you can include the port number in the connection path: \\servername:6262\path\dictionary.add.

Resources