Solved

Help connecting to db2 from SQLEXPLORER

Posted on 2009-07-11
3
2,082 Views
Last Modified: 2012-05-07
I'm trying to find an interactive admin/development environment for db2 on Windows.  I downloaded SQL Explorer, but cannot seen to connect to db2 on my home server.  My db2 instace is named as the default 'DB2COPY1' (but just shows up as DB2 in Control Center).  I have tried setting up a new SQL Explorer connection to my DB@ server as:

SQL Explorer Default driver:     'JDBC ODBC Bridge'
URL:     jdbc:odbc://localhost/db2copy1 (also tried just db2)
user:     mitch (A W2k3 domain user that I use to log into the server and I seem to gain full access to db2 without further authentication)

Keep getting error:

"Could not connect to your database alias; the excat message was:

Cannot connect to MyLocalConnectionProfile/mitch.  Check your URL [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

Do you want to try again?"

I'd really like to try this app out.  Bouncing back and forth from tab to tab in IBM's tools is slowing me way down.  I'm used to typing ad hoc queries and getting imidiate feedback in the same window.  Also would be nice to be able to explore schema/table structures and names without switcing windows too.
0
Comment
Question by:SQLMitch
3 Comments
 
LVL 45

Assisted Solution

by:Kdo
Kdo earned 20 total points
Comment Utility
Hi Mitch,

I've never used SQLEXPLORER, but it certainly looks like a fine tool.

The driver/URL looks suspicious.  Try this one:

  jdbc:db2://localhost/db2copy1



Good Luck,
Kent
0
 
LVL 5

Accepted Solution

by:
Brian Chan earned 30 total points
Comment Utility
It is certainly you have problem with driver. I have used two different SQL clients and so far I always have to use the IBM's java jdbc driver. Do you have access to IBM's download website? For drivers and client, I think you just need to registered an IBM ID and you will be able to download it.

The connection string should be then:

jdbc:db2://[hostname]:[port#]/[database name]

0
 

Author Closing Comment

by:SQLMitch
Comment Utility
Indeed I did have to download the jdbc driver for DB2 from IBM's website.  Then had to configure SQLEXPLORER to use this driver (the only driver that comes preconfigured with the download is the ODBC-JDBC bridge, which aparently requires an ODBC DSN set up on local machine in order to connect).  Once the db2 jdbc driver was instaleed and configured on SQLEXPLORER, the connection strings you recomended worked perfectly, thanks.
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

November 2009 Recently, a question came up in the DB2 forum regarding the date format in DB2 UDB for AS/400.  Apparently in UDB LUW (Linux/Unix/Windows), the date format is a system-wide setting, and is not controlled at the session level.  I'm n…
Recursive SQL in UDB/LUW (you can use 'recursive' and 'SQL' in the same sentence) A growing number of database queries lend themselves to recursive solutions.  It's not always easy to spot when recursion is called for, especially for people una…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now