Connectivity issue for netezza

Asked by Preetam Kumar Ojha

Hi ,

I am trying to connect to netezza using JPype/JayDeBeApi but having a silly connectivity issue -

It keeps on returning Invalid username. I have rechecked and the credentials are completely correct. Using these credentials I have logged into the database through other clients.

Strange thing to note - Even when I am not in network and try to run this program , I get the same error. So I think the problem is local to my system.

Here is the complete error log -

File "jdbc_conn_test.py", line 18, in <module>
    conn = jaydebeapi.connect('org.netezza.Driver','jdbc:netezza://xyz:5480/mydb',user,passwd)
  File "build/bdist.macosx-10.9-intel/egg/jaydebeapi/dbapi2.py", line 269, in connect
  File "build/bdist.macosx-10.9-intel/egg/jaydebeapi/dbapi2.py", line 117, in _jdbc_connect_jpype
jpype._jexception.ExceptionPyRaisable: java.sql.SQLException: Invalid Username

Question information

Language:
English Edit question
Status:
Solved
For:
JayDeBeApi Edit question
Assignee:
No assignee Edit question
Solved by:
Bastian
Solved:
Last query:
Last reply:
Revision history for this message
Best Bastian (baztian) said :
#1

The call should be
conn = jaydebeapi.connect('org.netezza.Driver', ['jdbc:netezza://xyz:5480/mydb', user, passwd])

From the docs:
The second parameter is a single argument or a sequence of arguments that are internally passed to the Java DriverManager.getConnection method. Usually this is the JDBC connection URL. See the Javadoc of DriverManager class for details.

Revision history for this message
Preetam Kumar Ojha (ojha-preetam) said :
#2

Thanks Bastian . This works fine. I probably read it wrong from the documentation.

Revision history for this message
Preetam Kumar Ojha (ojha-preetam) said :
#3

Thanks Bastian, that solved my question.