Bill Witherspoon wrote: >> Would you try something to see if we can figure this out? Below is >> code from dbMsSQL.py. The line numbers are the lines from the current >> version of the file; the lines without numbers are the debugging code >> I want you to insert. >> >> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - >> 24 port = str(connectInfo.Port) >> 25 if not port or port == "None": >> 26 port = 1433 >> 27 host = "%s:%s" % (connectInfo.Host, port) >> 28 user = connectInfo.User >> 29 password = connectInfo.revealPW() >> 30 database = connectInfo.Database >> 31 >> 32 # hack to make this work. I am sure there is a better way. >> 33 self.database = database >> 34 >> print "host:", host >> print "user:", user >> print "password:", password >> print "database:", database >> print "kwargs:", kwargs >> 35 self._connection = pymssql.connect(host=host, user=user, >> password=password, >> 36 database=database, **kwargs) >> 37 return self._connection >> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Is this some new form of diff/patch? :) >> >> Now try running the dialog that isn't working, and post what gets >> printed out. If that's not the correct connection parameters, then we >> can figure out why. >> > > Ed & Carl, > > I did add this debug code, and got the results expected - everything > looks as it should, except the self._connection line does not work. It > times out as it always has for me. and post what gets printed out It would help us if you did that when you talk about what you did and what you got. I can't be sure my idea of expected is the same as yours. > > I've experimented today by replacing the self._connection with a hard > coded connection string as below: > > > #fix this > #self._connection = pymssql.connect(host=host, user=user, > #password=password, database=database, **kwargs) > > #replaced with this: > self._connection = pymssql.connect(host="192.168.51.26", > user='plant_user', password="emseal01", database="testing") > > This actually works. That works when the server is set to Win auth only? I am assuming now that we know the python lib will do Win that you are no longger running the server with Mixed? > Is it possible there is something going on > transparently with string encoding (like Unicode)? Something that would > print the expected result to screen but still be passing something > unexpected to SQLServer? quite possible - I found some problem with the MsSql lib and Unicode. (speaking of, did you apply the patch? and if you have to ask "what patch?" then I'll just go with "what patches did you apply?" ) Carl K _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users Searchable Archives: http://leafe.com/archives/search/dabo-users This message: http://leafe.com/archives/byMID/dabo-users/[EMAIL PROTECTED]
