Add Update function with string identification logic