That would be indeed the easiest way, but it's a for-loop (lines out of a file) and not all strings have "", and some are empty. So i have strings like this: A12, "A12", "", and empty. I put this in the for loop and now i get that list ['A','2','3'] and empty lists for the empty strings (I have...
Can you put lists to strings as well with %? I got strings like: "A23". I've got to have the " removed. I used list to get it removed so now i have ['A','2','3'], but I don't know how to get it back as A23.
That works :)
This works too:
cursor.execute("select gene_stable_id, display_id from hsapiens_gene_est__gene__main where gene_stable_id = '" + ensemblid + "'")
Tnx
Hi, I have a script to search for strings in a file and look them up in a database, however sql won't accept my string (for example ENSG00000152822), how should I do it?
import MySQLdb
db = MySQLdb.connect(host = "ensembldb.sanger.ac.uk",user = "anonymous", passwd = "", db =...
It doesn't work yet. It says:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in c:\webserver\apache\htdocs\proj7\compsystems\med\uren_viewer.php on line 78
This is (a part of) the code I have now:
$query = "SELECT month(date) AS month...
Hi, Can anyone help me to make a sql query (for a php website/administrating system) in which to calculate with date and time??
There is: Userid, Begintime, Endingtime and Date. I have to get the hours a month (how much the person has worked that month). So userid x has worked y hours in...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.