November 1st, 2012, 01:15 AM
Php and mongodb synchronization
I have a website with volunteers that help to translate the website to other languages.
I am working with php along with Mongodb ,
how can I sync a collection update ?
for example :
2 volunteers wants to update the same record in a collection and enter in the same time .. they are both see the same translation now .. if someone has update the record while the other one is still working .. I want to prevent the other from updating and ruin the previous update made the the first user .
November 1st, 2012, 08:03 AM
Assuming you are using PDO, you want to use PDO transaction based coding.
There are 10 kinds of people in the world. Those that understand binary and those that don't.