I have a table with a string column (varchar(200)) that contain a date in different format. For example
may 24 1983 12:00AM
1981-01-13 00:00:00
1979-01-13 00:00:00:123
I want to convert this column in a date to extract year. How could i do? I have used STR_TO_DATE but don't work well. I must use SUBSTRING for each different format?
MySQL version 5.0.95