|
For me the question is not quite right.
I don't think row count, or class count should determine whether a database is used or not.
I think it's more a case of what you are going to do with the data.
If you think you may need to 'look' at the data occasionally, manipulate it or run some form of reports(statistics, counts, aggregation...) on the data than a database is the right choice even if you have as few as 100 rows.
If you are just reading in data that has already been 'cleaned' and all you are doing is transforming the data then perhaps a database is not necessary.
As others have mentioned there is no correct answer - whichever path you take there will be advantages and disadvantages.
My rule of thumb is not so much the volume of data, but what is going to happen to the data.
Regarding footprint - there are some databases which leave a reasonably small(suitably vague statement of the day...) footprint, particularly those where the database is structured as one file.
“That which can be asserted without evidence, can be dismissed without evidence.”
― Christopher Hitchens
modified 16-Apr-15 3:35am.
|
|
|
|
|
10,000 is very low number to compare anything for performance.
When you compare XML / Flat file with database the only advantage you get is write performance and cheaper cost. Which is never a deciding factor for any application, whether its enterprise or consumer.
The things you can get with database and not with xml are:
- Concurrency (You can control if you have insert/update at the same time on your data)
- Transaction Reliability (You can go back to an older data/snapshot to correct a mistake)
- Backup (You can configure very efficient backup policy i.e. log shipping / replication which is not possible with XML)
- Partitioning (You can store data to different database/location based on region and then retrieve it easily)
- Archiving (Transfer data to archive in realtime and then access it in realtime with linked database)
- Security (fine grain control over who can access what)
- And the most important, Well Structured and Connected Data (makes complex query for different reports very easy)
So I would suggest you to use XML for intermediate stuff, or to store settings. but other than that don't waste your time and efforts. Just go with the RDBMS.
And for Mobile device to store offline stuff you can use XML / JSON Documents (JSON is better than XML). But at the end you should have a RDBMS server and Sync your offline data to it.
|
|
|
|
|
I'd go for XML with anything that is just a few lines, like configuration. If it contains a lot of relations, I'd switch to SQLite.
If multiple users are to access the datasource, it would also become a real database. I don't want to have to implement things like table-locking.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
If you need any kind of concurrency it can quickly become messy with (xml)files.
|
|
|
|
|
It depends on the structure of the data.
For an example of why this is important, if look at the structure of CodeProject, as you should have before you posted, you will see that you have inserted a Message data item to the Lounge table, which is not where it belongs in the structure.
The effect of this is that stored procedures set up to resolve the type of problem in your Message object will not be able to find it with their pre-configured queries, so your problem will not be found, and will not be resolved.
The world will not end and civilisation will not collapse because of this (probably, but don't quote me if it happens), but it does demonstrate that if the data you have to handle has a complex structure, or many different branches, then storing it in large XML files, e.g. pages of the Lounge, is a pretty damned stupid thing to do.
... Almost as stupid as posting programming questions in the CP Lounge.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
wreckless wrote: Please enlighten me on the subject. Data Integrity
Jeremy Falcon
|
|
|
|
|
wreckless wrote: Just kidding about the rock stars
Good, 'cause anyone who thinks he's a rock star is actually just another hipster douchebag.
It's not about size. Others have pointed out some of the many concerns involved.
In short, XML is fine for configuration and reports, but not suitable for random access and multi-user access.
|
|
|
|
|
I knew I should have left the rock stars part out of it. I also learned it's not a good idea to ask a question when I've been drinking. It was just spontaneous combustion I guess. But what the heck, sh#t happens. (Like posting in the lounge, sorry bout that)
Lots of good answers here anyway, It looks to me like if it is simple keep it simple.
If it is complicated, keep it simple by using a database. That about sums it up.
But then again, how do you define simple? What simple for some may be Rock Science to others.
I guess it all depends on what is is?
wreckless
|
|
|
|
|
|
I think it's a good thing, as they're supposed to make sense to me.
And they often do, such as the free e-book on graph databases I have at this very moment on this page.
I can add that I make a point of not using any ad blocker as I believe in supporting CP.
But sometimes it just doesn't work as intended.
Like the other day, Russian mail order brides, well I can actually see how this is actually pretty well aimed at some of the people frequenting this site.
But can please someone explain to me how the clientele of this website is connected with ads for incontinence pads!
|
|
|
|
|
Jörgen Andersson wrote: incontinence pads!
Perhaps the relation is memory leakage.
|
|
|
|
|
Hmm I guess for some it is not a totally irrelevant subject, there are a bunch of old farts on this site, one of the more unpleasant aspects of becoming decrepit.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
You better show some respect for us decrepit old farts, mr Holmes. There are a lot more of us than there is of you. And every one of us has no difficulty squeezing a trigger!
|
|
|
|
|
I originally wrote: Hmm I guess for some of us it is not a totally irrelevant subject So yeah it pisses me off as well.
Sorry couldn't resist
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
It appears that at least some of weus old farts are still full of piss and vinegar...
If you have an important point to make, don't try to be subtle or clever. Use a pile driver. Hit the point once. Then come back and hit it again. Then hit it a third time - a tremendous whack.
--Winston Churchill
modified 16-Apr-15 1:57am.
|
|
|
|
|
Jörgen Andersson wrote: please someone explain to me how the clientele of this website is connected with ads for incontinence pads!
well I can actually see how this is actually pretty well aimed at some of the people frequenting this site.
Any questions? Targeted ads are based on your browsing history.
Once you lose your pride the rest is easy.
In the end, only three things matter: how much you loved, how gently you lived, and how gracefully you let go of things not meant for you. – Buddha
Simply Elegant Designs JimmyRopes Designs
|
|
|
|
|
JimmyRopes wrote: Targeted ads are based on your browsing history. Exactly. It's always funny when people ask about the ads they see not realizing that they are tailored to their own experiences.
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
Have you seen Q&A?
It's nicest effect is to generate incontinence...
|
|
|
|
|
My add says "Splunk! What can you do with Splunk?"
To be honest, I'm not sure I want to know what that is and what I can do with it!
Anything that is unrelated to elephants is irrelephant Anonymous
- The problem with quotes on the internet is that you can never tell if they're genuine Winston Churchill, 1944
- I'd just like a chance to prove that money can't make me happy. Me, all the time
|
|
|
|
|
I've been using Splunk for about a fortnight.
It's very good.
Although they still haven't fixed the typo for Splunk Mint[^] that I told them about (scroll down).
Perhaps the worst of their products to make the mistake on.
Some men are born mediocre, some men achieve mediocrity, and some men have mediocrity thrust upon them.
|
|
|
|
|
The hamsters try hard, but sometimes they slip through.
If you get inappropriate ads, let Chris know and he'll do something about it.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
You must have posted code samples.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
Even Google can't get it right all the time.
A few years ago when I was reading a reply to one of my posts from Nish in my browser, gmail gave me an ad for an Indian Arranged Marriage site.
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason?
Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful?
--Zachris Topelius
Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies.
-- Sarah Hoyt
|
|
|
|
|
|
Must be one of the mailmen who I recently told what I think about their service.
The language is JavaScript. that of Mordor, which I will not utter here
This is Javascript. If you put big wheels and a racing stripe on a golf cart, it's still a f***ing golf cart.
"I don't know, extraterrestrial?"
"You mean like from space?"
"No, from Canada."
If software development were a circus, we would all be the clowns.
|
|
|
|