ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Unable to connect Database on As/400 from windows MB7

Post new topic  Reply to topic Goto page 1, 2  Next
 Unable to connect Database on As/400 from windows MB7 « View previous topic :: View next topic » 
Author Message
tanishka
PostPosted: Mon Sep 13, 2010 7:41 am    Post subject: Unable to connect Database on As/400 from windows MB7 Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

Hi all,

I am working on MB7 on windows , and try to connect Database on As/400. We got iseries access for windows, Iseries Access ODBC DRIVER.

I created SYSTEM DSN and specified in datasource property of compute node. I am getting below error.

DatabaseException BIP2393E: Database error: ODBC return code '-1' from data source ''AS400DB''.
The broker received an error when executing a database operation. The ODBC return code was '-1'. See the following messages for information obtained from the database about this error.
Use the following messages to determine the cause of the error. Typical causes are incorrect data source or table names. Correct either the database or the broker configuration.
2010-09-13 11:35:12.211993 2544 DatabaseException BIP2322E: Database error: SQL State ''28000''; Native Error Code '8015'; Error Text ''[IBM][iSeries Access ODBC Driver]Communication link failure. comm rc=8015 - CWBSY1006 - User ID is invalid, Password length = 10, Prompt Mode = Never, System IP Address = 172.17.78.128''.
The error has the following diagnostic information: SQL State ''28000'' SQL Native Error Code '8015' SQL Error Text ''[IBM][iSeries Access ODBC Driver]Communication link failure. comm rc=8015 - CWBSY1006 - User ID is invalid, Password length = 10, Prompt Mode = Never, System IP Address = 172.17.78.128''
This message may be accompanied by other messages describing the effect on the message broker itself. Use the reason identified in this message with the accompanying messages to determine the cause of the error.
2010-09-13 11:35:12.212034 2544 DatabaseException BIP2322E: Database error: SQL State ''IM006''; Native Error Code '0'; Error Text ''[Microsoft][ODBC Driver Manager] Driver's SQLSetConnectAttr failed''.
The error has the following diagnostic information: SQL State ''IM006'' SQL Native Error Code '0' SQL Error Text ''[Microsoft][ODBC Driver Manager] Driver's SQLSetConnectAttr failed''
This message may be accompanied by other messages describing the effect on the message broker itself. Use the reason identified in this message with the accompanying messages to determine the cause of the error.

Please help me.
Back to top
View user's profile Send private message
Gaya3
PostPosted: Mon Sep 13, 2010 7:53 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

you should test it from outside at first than from Message broker.

try to connect the remote database through command prompt.

do a tnsping [i guess its for oracle] but try to understand it for AS400

lets resolve that first and get in to message broker.
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
tanishka
PostPosted: Mon Sep 13, 2010 11:32 am    Post subject: Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

Through Iseries Navigator access connection workig fine. From broker i am getting exception.
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Sep 13, 2010 11:36 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

What database is it on AS/400?

Which ODBC driver are you using? Is it one of the drivers supplied with WMBv7? If not, is it supported?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
tanishka
PostPosted: Mon Sep 13, 2010 11:46 am    Post subject: Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

DB2
iSeries Access ODBC Driver

It is not supplied with MB7 but it is supported.
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Sep 13, 2010 11:50 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

tanishka wrote:
It is not supplied with MB7 but it is supported.


Why not use the supplied DB2 driver?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
tanishka
PostPosted: Mon Sep 13, 2010 11:59 am    Post subject: Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

MB7 they don't supply DB2 DRIVER.
Back to top
View user's profile Send private message
tanishka
PostPosted: Mon Sep 13, 2010 12:01 pm    Post subject: Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

Please refer to below links..

http://publib.boulder.ibm.com/infocenter/iseries/v5r4/index.jsp?topic=/rzaii/rzaiiodbc23.htm

http://publib.boulder.ibm.com/infocenter/wmbhelp/v7r0m0/index.jsp?topic=/com.ibm.etools.mft.doc/bb45000_.htm
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Sep 13, 2010 12:12 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

tanishka wrote:
Please refer to below links..

http://publib.boulder.ibm.com/infocenter/iseries/v5r4/index.jsp?topic=/rzaii/rzaiiodbc23.htm

http://publib.boulder.ibm.com/infocenter/wmbhelp/v7r0m0/index.jsp?topic=/com.ibm.etools.mft.doc/bb45000_.htm


I know WMBv7 doesn't use a database internally, but I was unware it didn't ship with drivers.

As to the other, AS/400 is a foriegn country and I don't live there. If you're certain the driver is correct, then the "User Id is invalid" message gains credibility.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Amitha
PostPosted: Mon Sep 13, 2010 1:28 pm    Post subject: Reply with quote

Voyager

Joined: 20 Nov 2009
Posts: 80
Location: Newyork

Quote:
2010-09-13 11:35:12.211993 2544 DatabaseException BIP2322E: Database error: SQL State ''28000''; Native Error Code '8015'; Error Text ''[IBM][iSeries Access ODBC Driver]Communication link failure. comm rc=8015 - CWBSY1006 - User ID is invalid, Password length = 10, Prompt Mode = Never, System IP Address = 172.17.78.128''.


Looks like you haven't set userID password for datasource using mqsisetdbparms
Back to top
View user's profile Send private message Send e-mail
Gaya3
PostPosted: Mon Sep 13, 2010 1:33 pm    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Amitha wrote:
Quote:
2010-09-13 11:35:12.211993 2544 DatabaseException BIP2322E: Database error: SQL State ''28000''; Native Error Code '8015'; Error Text ''[IBM][iSeries Access ODBC Driver]Communication link failure. comm rc=8015 - CWBSY1006 - User ID is invalid, Password length = 10, Prompt Mode = Never, System IP Address = 172.17.78.128''.


Looks like you haven't set userID password for datasource using mqsisetdbparms


good catch, that could be one issue.
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
tanishka
PostPosted: Tue Sep 14, 2010 9:23 am    Post subject: Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

Thanks amitha, That command works.
Back to top
View user's profile Send private message
tanishka
PostPosted: Tue Sep 14, 2010 9:47 am    Post subject: Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

One more question here
I am selecting records from database.
some of the columns may not containing the data.
my requirement is count the columns which contains data.

SET POtype.Result[] = PASSTHRU('SELECT R.COL, R.COL1, R.COL2, R.COL3 FROM schema1.table1 AS R WHERE R.COL4 = ?' TO Database.schema VALUES ('PO'));

SET Environment.Varible.ID[] = LIST{TRIM(POtype.Result.COL), TRIM(TPOtype.Result.COL1), TRIM(TPOtype.Result.COL2),
RIM(TPOtype.Result.COL3)};

Here is the trace data.

Environment:

( ['MQROOT' : 0x1448e88]
(0x01000000:Name):Varible = (
(0x03000000:NameValue):ID = '070293485' (CHARACTER)
(0x03000000:NameValue):ID = '70293' (CHARACTER)
(0x03000000:NameValue):ID = '' (CHARACTER)


SET TPIDCount = CARDINALITY(Environment.Varible.TPID[]);

it retuns 3.

I No need null records. What should i need to do to avoid to store null records in environment varible.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Tue Sep 14, 2010 10:57 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

You can modify your SELECT statement so it doesn't return null columns.

You can run an ESQL Select against your Environment tree.

You can probably use a COUNT clause in a select to return the number you need instead of using CARDINALITY.
Back to top
View user's profile Send private message
tanishka
PostPosted: Tue Sep 14, 2010 2:03 pm    Post subject: Reply with quote

Centurion

Joined: 24 Nov 2008
Posts: 144

Mqjeff,

This is actual requirement.

SET POtype.Result[] = PASSTHRU('SELECT R.COL, R.COL1, R.COL2 FROM schema1.table1 AS R WHERE R.COL3# = ?' TO Database.schema VALUES ('PO'));

COL - required(value should be there)
COL1 and COL2 are optional ( blank)

Select statement returns spaces if value not exist.

I should populate list from these three columns.

If col2 and col3 contains spaces the list should populate with COL1.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page 1, 2  Next Page 1 of 2

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Unable to connect Database on As/400 from windows MB7
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.