Latvian address code
The nine-digit code identifying an address object in the state address register kept by the State Land Service.
The State Land Service maintains the register and states that the code stays unchanged for as long as the address object exists.
Nine digits: an eight-digit number with a check digit appended. The code is unique across every kind of object in the register, so a novads, a town, a parish and a village never share one, and the roughly 11,700 codes in the four published files collide nowhere.
The numeric ranges of the different kinds do overlap, so the type has to be read from its own column rather than guessed from the number. A place that is refounded receives a new code rather than recovering its old one: the village of Adazi closed in June 2022 and the town of Adazi opened the next day under a different code.
