Fix database index (avoid missing readings)