Train derails near Terry, dumping 29 coal cars