If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Duplicate logon to DB2

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-27-09, 17:50
syrider syrider is offline
Registered User
 
Join Date: Oct 2009
Posts: 3
Duplicate logon to DB2

Running a Powerbuilder 6.5 app, used to connect to MF database thru Sybase Direct gateway Connection. Attempting to convert to IBM DB2 ODBC (8.01) gateway, when app attempting to connect to the DB, the ODBC component seems to invoke another logon window 'Connect to DB2 Database', requiring duplicate logon process.

First logon procedure is Powerbuilder front end which passes all the parameters via 'sqlca' transaction object...I've checked the values passing from Powerbuilder, and the values seems to be all correctd.

Somehow when doing this conversion, ODBC invokes its own layer of logon window.

Anyway to successully pass parameters to ODBC w/o invoking another ODBC logon screen?
Reply With Quote
  #2 (permalink)  
Old 10-27-09, 19:45
LD_Bronstein LD_Bronstein is offline
Registered User
 
Join Date: Aug 2009
Posts: 23
It's been a while, but I recall that PowerBuilder allows complete CONNECT syntax in its VB-like language. I do not think that you will be prompted by ODBC if you specify both user ID and password on CONNECT.
Reply With Quote
  #3 (permalink)  
Old 10-27-09, 20:02
Marcus_A Marcus_A is offline
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,196
Quote:
Originally Posted by Somasundaram1
what is connect?
I will make a deal. You explain about TSM backups of a DB2 database and I will explain "connect." This guy is a troll.
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390
Reply With Quote
  #4 (permalink)  
Old 10-28-09, 00:21
LD_Bronstein LD_Bronstein is offline
Registered User
 
Join Date: Aug 2009
Posts: 23
Quote:
Originally Posted by Marcus_A
I will make a deal. You explain about TSM backups of a DB2 database and I will explain "connect." This guy is a troll.
Marcus, I think you appended to the wrong thread. What are you talking about? What is this about TSM and troll? ... ?
Reply With Quote
  #5 (permalink)  
Old 10-28-09, 01:31
Marcus_A Marcus_A is offline
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,196
Quote:
Originally Posted by LD_Bronstein
Marcus, I think you appended to the wrong thread. What are you talking about? What is this about TSM and troll? ... ?
Somasundaram1 was trolling and all his posts have been deleted. That is why it looks like I posted in the wrong thread.
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390
Reply With Quote
  #6 (permalink)  
Old 10-28-09, 14:02
syrider syrider is offline
Registered User
 
Join Date: Oct 2009
Posts: 3
Quote:
Originally Posted by LD_Bronstein
It's been a while, but I recall that PowerBuilder allows complete CONNECT syntax in its VB-like language. I do not think that you will be prompted by ODBC if you specify both user ID and password on CONNECT.
Yes! you are right, I don't want to get into PB too much, but to be brief...PB has 'DBParm' which read from a .ini file that includes as optional UID and Pass. If I hard code these parameters, then Yes! it connects w/o the additional DB2 logon screen from ODBC.

But since login will be dynamic, and password changes frequently, logon screen will load all the parameters to 'sqlca' transaction object and pass to ODBC...it seems to capture all the parms (ID pass...etc), but still no go once calling ODBC...
Reply With Quote
  #7 (permalink)  
Old 10-28-09, 15:46
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
Quote:
Originally Posted by syrider
logon screen will load all the parameters to 'sqlca' transaction object and pass to ODBC...
Unless you are talking about some other SQLCA, its purpose is to return status information _from_ DB2 to the application, so I doubt you can pass anything _to_ ODBC via SQLCA. I don't know much (read: anything) about PowerBuilder but I'm sure there should be a way either to compose the ODBC connection string dynamically or to set individual connection attributes before opening a connection.
Reply With Quote
  #8 (permalink)  
Old 10-28-09, 17:10
syrider syrider is offline
Registered User
 
Join Date: Oct 2009
Posts: 3
Quote:
Originally Posted by n_i
Unless you are talking about some other SQLCA, its purpose is to return status information _from_ DB2 to the application, so I doubt you can pass anything _to_ ODBC via SQLCA. I don't know much (read: anything) about PowerBuilder but I'm sure there should be a way either to compose the ODBC connection string dynamically or to set individual connection attributes before opening a connection.
SQLCA is a transaction object, it should pass all the collected values from the app to ODBC to make the connection, then pass the connect status back to app.

could not figure out why the SQLCA won't pass the ID and PASS info, but I've coded to dynamically populate the 'DBParm' ....works like a charm!
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On