One of my table has a field - business_location, with the following kind of records:
Hyde Park, QLD
Is there a quick way to extract the states, using a query?
I would like to take the last word and put into different column.
For example, extract VIC from "Ormond, VIC", using some features at mysql level to select().
using the space as the delimiter, pull off the last word like this --
SUBSTRING_INDEX(business_location, ' ', -1)
I have checked my entire data that the last words are always one-word as the state.