Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Python and MYSQL Resultset
#1
Hi - I am using Python to get results from mysql database.
The results displayed shows quotes and a u concatenated to the results? Not sure why?

Result:(1, u'userone', u'password1')
Reply
#2
Read this thread https://stackoverflow.com/questions/3920...ql/3920490
vj78 likes this post
Reply
#3
(Apr-01-2021, 12:12 PM)kashcode Wrote: Read this thread https://stackoverflow.com/questions/3920...ql/3920490


Thank you. It did remove the u from the result set. After adding the use_unicode=True ,charset="utf8" to the db connection string.

Now, I still have single quotes left in the result set?
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  AttributeError: ResultSet object has no attribute 'get_text' KatMac 1 566 May-07-2021, 05:32 PM
Last Post: snippsat
  TypeError: must be str, not ResultSet HiImNew 3 5,184 Feb-15-2018, 07:48 AM
Last Post: buran

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020