I am a beginner user in Python. I have a problem. I am writing a program that runs MySQL query under Python, and I get the result as a tuple of dictionaries. One of the key:value pairs is "Sequence" : array =("xxxx...").
To get out only the sequence ("xxxx...") I used the following command:
for record in data: # data is the result of the query
seq=record["Sequence"].tostring()
However this loop interfers in some way with the rest of the code in the programme.
Is there any other way to get out the sequence to have it as a string and not array?
I would be grateful for any help,
Aga
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello!
I am a beginner user in Python. I have a problem. I am writing a program that runs MySQL query under Python, and I get the result as a tuple of dictionaries. One of the key:value pairs is "Sequence" : array =("xxxx...").
To get out only the sequence ("xxxx...") I used the following command:
for record in data: # data is the result of the query
seq=record["Sequence"].tostring()
However this loop interfers in some way with the rest of the code in the programme.
Is there any other way to get out the sequence to have it as a string and not array?
I would be grateful for any help,
Read the User's Guide. You need to modify the conversion dictionary.