Certified GKH Gardening Expert
Some plants can handle it, some cannot. There are, also, many other factors at play, such as how long it has been planted, if it is already stressed and how badly.
If you know that the soil is a better fit, then it may be best to do so. Unfortunately, without knowing much about the plant, or situation, I am unable to say whether this is the best move or not.