When I query
cs = con.cursor()
cs.execute("USE DATABASE DEV_TEST")
cs.execute(r"SELECT column_name FROM INFORMATION_SCHEMA.COLUMNS")
it retrieves the data but if I put a WHERE
clause it returns nothing
cs.execute(r"SELECT column_name FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='TESTTABLE'")
Can you help me what I'm doing wrong
Note: TESTTABLE
table exists in a right location
Enclose variable names in double quotes.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.