Pregunta de entrevista de Esri

A programming question: First duplicate character in a string, writing SQL query.