473,794 Members | 2,880 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Need Help with pymssql

Hi,
I am trying to connect to sql server 2000 on win xp. I am using a
python extension called. pymssql but it is giving me this errror:

Traceback (most recent call last):
File
"C:\Python22\Li b\site-packages\Python win\pywin\frame work\scriptutil s.py",
line 310, in RunScript
exec codeObject in __main__.__dict __
File "C:\syndication \db_1.py", line 3, in ?
con = pymssql.connect (host='abc',use r='ag',password ='ag',database= 'agl')
File "C:\Python22\Li b\site-packages\pymssq l.py", line 277, in connect
con = _mssql.connect( dbhost, dbuser, dbpasswd,dbport )
error: Can't Connecting MSSQL Server
Everything like server username and password are correct. can someone help
me . There is almost no help available on sourceforge for this. Any help
would be appreciated.

Please reply,
Regards

Khawaja Shahzad

_______________ _______________ _______________ _______________ _____
Free up your inbox with MSN Hotmail Extra Storage. Multiple plans available.
http://join.msn.com/?pgmarket=en-us&...ave/direct/01/
Jul 18 '05 #1
0 1531

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1486
by: Josh Close | last post by:
I'm getting an error from pymssql when trying to execute a stored procedure: Operating-system Error - OpenClient I can't figure out why this is happening. It's probably a freetds problem (like usual) but if any one knows, it would be helpful. This is all that's done: sql = 'spName;'
0
1564
by: saqib | last post by:
I have a query that is running on a mssql DB that takes about 15 minutes when run "directly"; IE: thru MS SQL Query Analyzer. I know, it sucks. I'm trying to fix it. But in the meantime, I have a python process which connects to the DB using pymssql. This process runs the aformentioned query... but fails because the query times out after approx 30 seconds. Is there anyway to change/set the timeout setting on a pymssql DB connection?? I...
1
2850
by: morris carre | last post by:
I have a strange problem : some code that fetches queries from an mssql database works fine under Idle but the very same code run from a shell window obtains its strings garbled as if the encoding codepage was modified. This occurs only when using pymssql to connect; if I connect through odbc (using the odbc module included in pywin) this problem vanishes. I briefly thought sys.getdefaultencoding() would pin it down but the value is...
1
5514
by: eight02645999 | last post by:
hi i am using pymmsql to query a date column in MSSQL database table. However the result shows for example (datetime.datetime(2006, 2, 16, 17, 50, 19) which is supposed to be 2006-02-16 17:50:19.000 anyway to correct query a date column using pymssql so that it gives the correct date format? thanks
0
995
by: Rony Steelandt | last post by:
I would like to use SQLDict against a MS SQL server database, but got stuck at the very beginning import pymssql import SQLDict # Connect to database c=pymssql.connect('192.168.1.13:dblisamaster:sa')
1
2619
by: joel.sjoo | last post by:
I'm a dba for SQL server and I Will import a textfile to SQL. For example I use a file with 3 columns. ID, Name and Surname and the columns are tab separated. I don't know much about programming. Anyway, I use this code below. It works, but it will not split the columns. I have tried to change the argumnts in str(alllines) Some of the columns can include many characters and some not. For exampel names can be Bo or Lars-Ture. I be glad...
1
6714
by: m.biddiscombe | last post by:
Hi, I'm trying to use pymssql to execute a stored procedure. Currently, I have an Excel spreadsheet that uses VBA in this manner: Private Function CreateNewParrot(connDb As ADODB.Connection) As Long Dim objCommand As ADODB.Command Dim iParrot As Long Dim bSuccess As Boolean
0
992
by: Fredrik Lundh | last post by:
Samuel Morhaim wrote: reading the documentation might help: http://pymssql.sourceforge.net/troubleshooting.html#dbid </F>
4
1294
by: gdyren | last post by:
the code is below: import pymssql conn = pymssql.connect(host = "121.198.126.233",user = "xxxx",password = "xxxx",database = "test") print "connecting success" cursor = conn.cursor() cursor.execute("insert into bbs_test values(%s,%s,%s,%s,%s)", ("1","nju","9:13","ustc","test")) cursor.close() conn.close()
0
9672
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10435
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10213
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10163
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10000
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7538
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5436
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5563
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2920
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.