user: Question: What is First elected that has Republican Party and a Result of Retired Democratic gain?
Columns: ['District', 'Incumbent', 'Party', 'First elected', 'Result']
Types: ['text', 'text', 'text', 'text', 'text']
Sample row: ['California 1', 'William Rosecrans', 'Democratic', '1880', 'Re-elected']
SQL:

assistant: SELECT "First elected" FROM "Table" WHERE "Party" = 'Republican' AND "Result" = 'Retired Democratic gain';