View Full Version : databases vs. xml... what gives?
12-24-2002, 11:46 PM
I've read extensive articles on xml, and I still don't understand how it might be the future of webuilding.
I figure, xml saves all the information as various datatypes, and you can see it in the format you see fit. How is that any different from using some language to call in from a database? Or have i seen it from the wrong light?
Any thoughts? If you think xml is better, could you please state why, I'm wondering if its worth learning or not for later projects. How would you use XML over a database itself?
The advantage of XML does not lay in databases. Any database is faster than a flatfile, including XML. The power of XML lays in the fact that the file describes the information itself.
Is a lot more informative than a table-based structure, such as MySQL.
Also, since XML is very open, there are a lot of other things possible with it. SVG, MathML, XSLT, XUL, all sorts of very powerful XML applications are already at your disposal.
12-25-2002, 01:32 AM
It's been used in Flash for years as a means of storing data - both content and layout/structural - outside the main *.swf.
xml is primarily about data interchange, not data storage. The key power it provides is to completely seperate data, data definition, and functionality (including presentation) while making these all easy to share.
If I send you an xml file (data), I should include a dtd. The dtd tells you what each element in the file means. This is something that databases simple do not do.
12-26-2002, 03:54 AM
a database can hold the data , metadata and attributes (even validation) etc that an XML file contains, any DB + SQL is a super method for cranking out XML files in the format required, rather than say XML to MXL transformations + also of course it can pump out the data directly into an non-xml application or data stream.
I am trying harder than ever these days to use XML and actually succeeding occaisionally, but in every instance I have found it far easier to store not XML files but a DB representation of such and call that when required.
I think you would be mad to not learn XML (the basic-basics are pretty straightforward) as it is already used in a wide range of applications etc (simple RSS newsfeeds for example are a good example), understanding XML will probably be as important as understanding HTML in the very near future.
But XML vs DB ? I dont think thats a straight fight, I think that a combo of both can be a powerful tool
just my tuppence-worth
Powered by vBulletin® Version 4.2.2 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.