Re: got different result from same filter in requests(django1.5)

2013-08-05 Thread Zhouhf
I found, each request will call a new connection to mysql in django1.4 while not in django1.5, in django1.5, connections will be cached and reused by new requests. Thus, there be a problem, the MySQLdb need a explicit connection.commit() before or after every connection.execute() in order to g

got different result from same filter in requests(django1.5)

2013-08-05 Thread Zhouhf
recently I ran into a problem whitch doubt me a lot, I did some UPDATE in MySQL: UPDATE tablename SET content="B" where content="A"; and commit, exit shell of MySQL then **with no reload uwsgi** model.objects.filter() in views.py just got different result in requests,like: (request1) htt