Commit 71eb746c authored by Kevin Modzelewski's avatar Kevin Modzelewski

Merge pull request #641 from toshok/increase_sqlalchemy_time

do 100 queries per insert instead of 1000 after all inserts.
parents 1bc20596 12e00f4e
...@@ -64,9 +64,8 @@ for i in xrange(100): ...@@ -64,9 +64,8 @@ for i in xrange(100):
session.add(new_address) session.add(new_address)
session.commit() session.commit()
# do 100 queries per insert
# now do 1000 queries for i in xrange(100):
for i in xrange(1000): session.query(Person).all()
session.query(Person).all()
print "done" print "done"
...@@ -56,10 +56,9 @@ for i in xrange(100): ...@@ -56,10 +56,9 @@ for i in xrange(100):
new_address = Address.insert() new_address = Address.insert()
new_address.execute(post_code='00000')#, person=new_person) new_address.execute(post_code='00000')#, person=new_person)
# do 100 queries per insert
# now do 1000 queries for i in xrange(100):
for i in xrange(1000): s = Person.select()
s = Person.select() rs = s.execute()
rs = s.execute()
print "done" print "done"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment