The Tamron 100-400 mm is good one, it is not as well made as the Canon sony 100-400 mm, but it costs lot more less.
The Tamron 18-400 mm is the one we called all-in-one zoom lens. It is not as good as the Tamron 100-400 mm.
Also the Tamron 100-400 mm is the Full-Frame lens, which can be used in Full-Frame camera ( usually like the pro camera), but the Tamron 18-400 mm is the APS-C-only lens, which is not compatible with the Full-Frame camera. That is why the Tamron 18-400 mm is cheaper.