I have a postgres table 'labs' with two columns (col1 varchar, col2 varchar).
col1 | col2
1.2.3 | a
1.2.3 | b
3.4.4 | c
3.4.4 | d
2.6.9 | e
2.6.9 | f
I would like to replace col1 with an integer like this
col1 | col2
1 | a
1 | b
2 | c
2 | d
3 | e
3 | f
Does anyone know an efficient statement to do this?