update i DBfunction