I have wrote a python daemon for read a database… I do the next:
db.connect('localhost', user, pass, database)
while true:
cursor = db.cursor()
sql = "SELECT id FROM task WHERE status='pending'"
r = cursor.execute(sql)
if r != 0:
result = cursor.fetchall()
#.....
The problem is that: when change database, the daemon not detect it… can refresh…
what can I do??
thanks!!
I have soluted it activating commit at the end of the script:
thanks for all friends