Adds data changing flags
Publishes changes in DB