Link to home
Start Free TrialLog in
Avatar of holemania
holemania

asked on

SQLBase ODBC Setup

I am having a hell of a time trying to connect to a sqlbase database from a remote machine.  The software is ADP and this is located locally on the machine.  I need to extract some data, but when I setup my ODBC, I am getting the following error when testing my connection:  "Connection failed with SQL State: "08001"".

In my ODBC setup, I set the DSN name, database name, put in username/password, leave everything default and then config file, I point that to the remote computer that has the ini file as followed:  \\ipaddress\C$\ADP\SQLBase\sql.ini.  Also tried copying the sql.ini file to my Gupta folder and point it there.

When I did my test I get above error with the 08001 number.  Anyone have any idea what I did wrong?
Use this when I point the config file to the remote computer.
 
[dbnt1sv]
servername=server2,sqlapipe
dbname=pay4win,sqlapipe
cache=2000
sortcache=2000
readonly=0
locktimeout=3
dbdir=C:\ADP
 
This is what I use when I copy the config file to my computer.
 
[dbnt1sv]
servername=server2,sqlapipe
dbname=pay4win,sqlapipe
cache=2000
sortcache=2000
readonly=0
locktimeout=3
dbdir=\\ipaddress\C$\ADP

Open in new window

Avatar of Qlemo
Qlemo
Flag of Germany image

Your are showing the SERVER part of the sql.ini. You need the CLIENT part, starting with [win32client].
Avatar of holemania
holemania

ASKER

Below is the client part.  This is local on the user's computer and I am trying to create an ODBC from my end to extract some data.  So is there anything that I need to do to the sql.ini file and should I copy this to my machine and point to it from the ODBC setup?
[win32client]
clientname=Win32User
 
[win32client.dll]
comdll=sqlapipe
comdll=sqlodb32
;comdll=sqlapipe
;comdll=sqlspx32
;comdll=sqlws32
;comdll=sqlwsspx
;comdll=sqlntnbi
 
 
[win32client.apipe]
 
[win32client.ntnbi]
;RetryTimeout=10
 
[win32client.ws32]
;serverpath=server1,<TCP-ADDRESS>/pay4win,*
 
[win32client.spx32]
 
[win32client.wsspx]

Open in new window

You will need at least this for using TCP (Pipes are unreliable). You can use local or remote sql.ini.

[win32client]
;clientname=Win32User
 
[win32client.dll]
;comdll=sqlapipe
;comdll=sqlodb32
comdll=sqlws32
 
[win32client.ws32]
serverpath=server2,<TCP-ADDRESS>/*

Open in new window

Tried as you suggested with no luck either.  I commented out what you posted.  Went and to the ODBC setup and point it to the ini file.  Still getting the same error.  
You changed the <TCP-ADDRESS> for sure?
And you have to change the server file, too, it is using only Pipes:

[dbnt1sv]
servername=server2,sqlws32
dbname=pay4win,sqlws32
cache=2000
sortcache=2000
readonly=0
locktimeout=3
dbdir=C:\ADP

and restart SQLBase.
Yes, this is changed in the ini file on my computer and had the other person reboot their machine.  Below is what I change on my machine, not sure if this needs to be change on the computer where ADP is located?  I commented out the IP address section, but I did put that in there.

[win32client]
;clientname=Win32User

[win32client.dll]
comdll=sqlws32
;comdll=sqlodb32
;comdll=sqlapipe
;comdll=sqlspx32
;comdll=sqlws32
;comdll=sqlwsspx
;comdll=sqlntnbi


[win32client.apipe]

[win32client.ntnbi]
;RetryTimeout=10

[win32client.ws32]
serverpath=server2,<myip address here>/pay4win,*

[win32client.spx32]

[win32client.wsspx]

[dbnt1sv.comments]
;
; This section is for the 1-User SQLBase Win32 database server.
;

[dbnt1sv]
servername=server2,sqlws32
dbname=pay4win,sqlws32
cache=2000
sortcache=2000
readonly=0
locktimeout=3
dbdir=C:\ADP

[dbnt1sv.dll]
comdll=sqlws32

[dbnt1sv.apipe]
ASKER CERTIFIED SOLUTION
Avatar of Qlemo
Qlemo
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Ah my bad on the IP address comment.  That is the server ip address and not mine.  

Now does the ini file on the server need to be change also?  Note that I am changing the ini file from my machine only so that I don't affect what the user is doing.  So i made the above changes to the ini file on my local machine.  Went to ODBC and put DSN, database name, username/password, and point the config to the one on my computer.  Went to test connection and put in SERVER2 as the server name, but still getting the connection failed error.

Probably missing something I guess.  I will do some more poking around today and update.
Hmmm still seem to have one hack of a time trying to connect to this standalone ADP.  When I contacted ADP support, they said that they don't support connecting to ADP via ODBC, so I'm kind of dead in the water.

We have an online version that I can connect to fine.  However, my other site has a standalone solely for just that site and I am having a heartache connecting to it.

The only things which can be cause a failure if both sql.ini's are correct is the open/transaction/access mode of ODBC driver.
Or TCP connection is not working at all for SQLBase, because of firewall for example.
Never thought of firewall.  Might be something I"m missing.  I can connect to the online version that is being shared by 3 people, but this standalone is giving me heartburn.  Will check to see if it's firewall blocking me.
I can't seem to get this to work, but found a workaround.  Created an automated job that run report smith pulling the info that I need on a nightly basis straight from that machine.  From there, I created a service that would grab the excel file and import this into a temp database where I can do whatever is needed with the report.

Thanks for your assistance.