Hi,

I try update large data:

create_price = []
for x in range(0, 10900):
    price = Price(int(array_name[x]), extra=0)
    create_price.append(price)
session.add_all(create_price)

#
for y in range(1, 10901):
    session.query(Person).filter_by(id=y).update({"price_id": 
create_price[y]},
                                                    
 synchronize_session=False)
    session.commit()

But this is not wery good idea?This is very slow..does anyone have an idea?

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to