i feel flat file is small and easy .....why we didn't use it.........?
Jeroen T Wenting
Joined: Apr 21, 2006
A great percentage of things for which XML is used could indeed be done just as easily or better using a fixed format textfile. This is in no small part a leftover from 5+ years ago when "XML" was a major buzzword that was massively hyped and everyone scrambled over eachother to use it whereever they could think of it. Being able to say you were using XML made your product instantly desirable to managers everywhere, in fact many IT departments were ordered to implement XML in every project by CEOs who wanted their companies to be seen as "modern" or "trendsetters". This led to XML configuration files where standard Windows ini files or Java properties files would have been far easier to use and far more efficient, and that attitude is in part still with us to this day.
The advantage of XML lies mainly in being (if properly constructed) easier to read, being more or less self-documenting. When having hierarchical data structures (multiple children for a record) which aren't easily implemented using fixedformat records without serious data duplication XML comes into its own though.