update group+department+device tables