I think if I am not wrong, you just need to put jdbc b2 bname where dbname is your database name. You also need to create this connection in your DB2 Control Center. Go to your Control Center, expand to the databases node and right-click. Select "Add" and select the database.
Joined: Jan 31, 2002
You are telling to add alias name in the control center and use it... but i dont want to create alias for my remote database. My aim is to remove hard coding. I can connect to remote database by alias and give that name in connecting database. but the problem is if i shifted my application to client side again i have to configure alias for that i have to give user and password. I want to eliminate entire thing and connect db2 using ip address. not through aliases.. could you please help me in this regards just like in oracle by ip and port of remote machine...