You definitely made a mistake using dirt from the ground, since it's not soil at all. But changing the soil... that's pretty tricky man. People go from soil to hydro, but once you get the plant out of the soil I can't really imagine how you could nicely re-plant it without causing some stress, or quite possibly worse than that.

If there's a lot of sulfur in the area the dirt lying around is probably very bad. Hate to say it but Mg def is probably the least of your worries man.