Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   XML (http://www.programmingforums.org/forum28.html)
-   -   About SQL and XML (http://www.programmingforums.org/showthread.php?t=13542)

pal Jul 12th, 2007 10:37 PM

About SQL and XML
 
Is it possible to have every bit of thousands of user information to be stored in XML? If so, what is pros and cons about the security? (Compared to SQL database)

ReggaetonKing Jul 12th, 2007 11:24 PM

Just think about the way databases are setup. Databases are built in such a way that changes to the structure does not effect any of the program used to access the databases. Where in a XML file, you would have to actually change some of the code thats parsing the XML file to retrieve data. Databases minimizes space as oppose to having a file increasingly grow and as it grows, the time to access information in files is increasing as well. Databases also restrict changes to it unless made by an authorized administrator and who are right to which tables in the databaes. They can also monitor activity to the changes made and if a system fails data is not lost!

DaWei Jul 13th, 2007 2:56 AM

XML is not a form of storage, it's a way to mark things up in a hierarchical manner.

King Jul 13th, 2007 9:11 AM

XML can be used for many things such as message passing, configuration, and data storing. For a big project you should use an actual database for data storage, but for a small local app XML would be just fine.

DaWei Jul 13th, 2007 9:15 AM

Again, XML is a format, not a storage methodology. You could store it in a flat file, or in a database, or on a piece of paper, or whatever.

King Jul 13th, 2007 9:32 AM

XML is a format which is nice to to store certain information in because it makes it easy to access different things you need in the file. For example configuration settings. I have worked at a couple places that use XML files for this purpose. As for using them to hold user data and such things a database would for sure be the better choice. But for a small local application, I don't see why using an XML file would be a bad thing.

DaWei Jul 13th, 2007 10:27 AM

I'm not saying it's a bad thing. I'm merely trying to correct the perception that it's a storage methodology. The particular container is the methodology. What's in the container might be XML or plain text or any number of things. The container might be a flat file or a relational database or something else. One chooses the format for good reasons and one chooses the container for (other) good reasons.

King Jul 13th, 2007 6:08 PM

Quote:

Originally Posted by DaWei (Post 130591)
I'm not saying it's a bad thing. I'm merely trying to correct the perception that it's a storage methodology. The particular container is the methodology. What's in the container might be XML or plain text or any number of things. The container might be a flat file or a relational database or something else. One chooses the format for good reasons and one chooses the container for (other) good reasons.

OK I see what you are saying now ;)


All times are GMT -5. The time now is 4:51 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC