added db update function example