Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Accessing SQL/MP using pyodbc.

452 views
Skip to first unread message

Andrew

unread,
Apr 9, 2013, 2:30:06 PM4/9/13
to
Hello,

I have been trying to access some of our SQL/MP databases using the non-stop odbc driver and the pyodbc api. I have been having problems with pyodbc and want to know if this is even possible? Have any of you got this working?

ODBC driver version: 2.10.20004.02

Pyodbc version: 3.0.6

Python version: 2.7

pyodbc error:

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
pyodbc.Error: ('08001', "[08001] [Tandem][ODBC Driver] Unable to connect to data
source (10060) (SQLDriverConnect); [01000] [Microsoft][ODBC Driver Manager] The
driver doesn't support the version of ODBC behavior that the application reques
ted (see SQLSetEnvAttr). (0)")

Robert Hutchings

unread,
Apr 9, 2013, 4:14:03 PM4/9/13
to
Hi..

Can you show us your "connect" statement, i.e.
"cnxn = pyodbc.connect('DRIVER={SQL Server};SERVER=localhost;DATABASE=testdb;UID=me;PWD=pass')"

or something like that...obviously you have a version mismatch somewhere between pyodbc/ODBC/NonStop SQL/MP...

Andrew

unread,
Apr 9, 2013, 5:30:26 PM4/9/13
to
Hey Robert,

I have tried a few different methods of connections string and different API's which all give that same behavior error. Honestly the biggest question I have is if it's even possible to use python at all.

example:

db = pyodbc.connect('DRIVER={NonStop SQL};SERVER=10.10.10.10;DATABASE=my_nonstop_catl;UID=Andrew;PWD=12345')

Robert Hutchings

unread,
Apr 9, 2013, 6:41:15 PM4/9/13
to
I am not sure about Python, although ODBC shouldn't really care about what language is used to create a connection. The NonStop OBBC Server product has a command-line interface called noscom (if memory serves..). There may be some informational commands that would help in this case...

Andrew

unread,
Apr 9, 2013, 7:53:46 PM4/9/13
to
Hey Robert,

Some good news. I have got it running. I believe it was because I was using a very old version of the non-stop odbc driver. I added the new version and deleted all the DSNs and did the odbc test and it worked. Pyodbc is also working.

How do I flag post as fixed?

Robert Hutchings

unread,
Apr 9, 2013, 8:09:09 PM4/9/13
to
Oh, cool! I don't know how to mark this as fixed...I guess people can just read the thread and see that it is fixed.

Good work Andrew!

Bill Honaker

unread,
Apr 10, 2013, 12:26:24 AM4/10/13
to
One thing you could share for future reference is the versiosn of the
ODBC/MP server on NonStop and the ODBC Driver that worked. This
information is available in the softdocs for each version of the
server but it would help to know that this particular version works
with pyodbc. You already posted thy pyodbc version.

Thanks, and great work!

Andrew

unread,
Apr 10, 2013, 3:05:08 PM4/10/13
to
I used the following. I am not sure what version of odbc is running on our non-stop.

windows xp SP3 32bit
python 2.7 32bit
pyodbc-3.0.6.win32-py2.7
NonStop ODBC driver: 2.10.20508.18
SQL/MP version: A350

Robert Hutchings

unread,
Apr 11, 2013, 7:31:52 PM4/11/13
to
OK, thanks Andrew.


UDAY

unread,
Apr 14, 2021, 9:04:34 AM4/14/21
to
On Friday, April 12, 2013 at 5:01:52 AM UTC+5:30, Robert Hutchings wrote:
> OK, thanks Andrew.
How can i get DRIVER={NonStop ODBC/MX 3.6} driver?

UDAY

unread,
Apr 14, 2021, 9:07:13 AM4/14/21
to
I am getting error when using that NonStop Sql in driver field, help is very much aooreciated.



Randall

unread,
Apr 14, 2021, 3:05:54 PM4/14/21
to
On Wednesday, April 14, 2021 at 9:07:13 a.m. UTC-4, UDAY wrote:
> I am getting error when using that NonStop Sql in driver field, help is very much aooreciated.

Can you share the error that you are getting? I'm not sure help can be given if we don't know the error.

Bill Honaker

unread,
Apr 14, 2021, 3:11:57 PM4/14/21
to
Can you provide more details? Based only on the thread this was posted in, are you looking for the OSS ODBC driver to run on the NonStop within Python?
Or are you looking for ODBC Drivers for Windows or Linux?

If it's the OSS driver it should be installed on your server along with SQL/MX. It should be documented in the manual, search the Nonstop Manuals at HPE.

Bill Honaker

unread,
Apr 14, 2021, 3:13:10 PM4/14/21
to
On Wed, 14 Apr 2021 06:04:32 -0700 (PDT), UDAY <udayred...@gmail.com> wrote:

Bill Honaker

unread,
Apr 14, 2021, 5:00:39 PM4/14/21
to
On Wed, 14 Apr 2021 06:04:32 -0700 (PDT), UDAY <udayred...@gmail.com> wrote:

The latest manual I found is this one: https://support.hpe.com/hpesc/public/docDisplay?docLocale=en_US&docId=c03682428

It is for 3.2.1, but the location and usage is the same, I believe.It says that the driver is ZODBCDLL and is in $SYSTEM.ZMXODBC...
However on the J series I just logged into it'sa actually YODBCDLL. It's probably different on L series.

I would suspect that a symbolic link might be installed in /usr/lib... But I don't see any signs of that.

If the version you have on your system is not 3.6, you will need to get the updated driver through HPE support. It has to be installed by your systems manager.
It's typically installed with an SPR or RVU, using Software Essentials.

UDAY

unread,
Apr 15, 2021, 9:56:48 AM4/15/21
to
pyodbc.Error: ('01S00;,'[01S00] [Microsoft][ODBC Driver Manager] Invalid connection string attribute (0) (SQLDriverConnect)
is the error i am getting


code:
import pyodbc
usr = "xxx"
pas = "xxx"
conn = pyodbc.connect('DRIVER={NonStop ODBC/MX 3.6};SERVER=TCP:127.0.0.1/18000;UID=%s;PWD=%s' % (usr,pas))
cursor = conn.cursor()

same thing replacing server ip:port , username and pwd

UDAY

unread,
Apr 15, 2021, 10:11:29 AM4/15/21
to
and i am able to connect to database using java and jdbc

Bill Honaker

unread,
Apr 16, 2021, 4:33:30 PM4/16/21
to

Uday,

Thank you for finally telling us this is for a client on Windows.

The ODBC/MX Client Drivers manual should answer all your questions:

https://support.hpe.com/hpesc/public/docDisplay?docLocale=en_US&docId=a00090058en_us

Page 20 of the PDF tells you where on your NonStop you can find the client drivers, and details the installation procedures.
Verification of the install is desceribed at the bottom of page 23.

At the bottom of page 26, configuration of data sources is described for Windows.

On page 33, the Data Source configuration is described. There is no automated discovery for SQL/MX ODBC sources.
Your system managers will have to give you Network, Data Access, and credentials information.

I hope that the information in the Manual is helpful to you.
Bill
0 new messages