ODBC connect from ms access to DB2

I have an ODBC connection showing in the System DNS window of the ODBC Data Source Administrator.  I made this connection a few months ago and it has been working fine.

This afternoon I was in my ms access program and tried to link a db2 table but got a connection error.  I went back to the connection - went to the Data Source tab & clicked on the Connect button to test the connection.

After a while it came back with a message "Connection tested successfully."

When I go to try to link a db2 table in my access database - I go to - External Data - ODBC Database - link table - Machine Data Source - click on my connection - I get ODBC -- call failed - attached error message.

My connection was working fine this morning - was able to run some queries.  Also each time I click on the test connection button it says I connect successfully.

Any suggestions?

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Kent OlsenDBACommented:
Hi John,

What flavor of DB2 are you running?  (Mainframe, AS400, or LUW.)

If you're connecting with TCP/IP, test connectivity to the database.

- Determine what TCP/IP port the database is using.  50000 is the default, but it's often changed.
- Determine the IP address of the database server.  The error message suggests

Now try to connect to the database using telnet.

- Open a command prompt.
- Type:  telnet 50000  {Change IP address and/or port as needed.)

You should get a blank screen and (optionally) a prompt.  If so, everything else should work.

Otherwise, you'll get an obvious error.  Probably immediately.  If the IP address and port are correct, check with the network guys to make sure that no firewalls (including Windows Firewall on the database server) are interfering with the connection.

Good Luck,

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Benjamin Van DitmarsSr Network EngineerCommented:
Steps to check youre problem

Check if you can ping the remote host
check if you can open an telnet session to the sql port and see if you get an connection, or an connection refused message.

if you cant connect disable youre windows firewall, if you still are not able to connect. write down youre own ip address and gateway and ask youre network/firewall administrator to check if things has changed in the configuration. they can also try to use an packet anayler to look in to the traffic where it is going wrong.

good luck, and hope you get it working soon.
Kent OlsenDBACommented:
Hi John,

Out of curiosity, what proved to be the problem?

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.