set id before reading it