Hi! I'm not sure which forum to place this in, so if there is a more appropriate one, please move it or let me know and I will repost it there. thanks.

A while back I developed a simple vb.net program for keeping track of rebates. I didn't want to use a database like access or msde because I don't want the overhead in file size and I especially don't want to have to have users install another piece of software in their system just to use my program...

so I implemented it using xml. I made a dataset and put in tables for the stores and the individual rebates. it worked really really well! the only problem is that because it's xml and a dataset, it has to load the entire file into memory when the program loads, and manipluate it in memory and write back to the file as a whole.

see, I like the idea of using a database because it only accesses the informaiton you need for that particular rebate. there is a performance hit because it has to retrieve each time you change rebates/stores, but you would always only be looking at one at a time, so there is no need to have them all in memory.

does any of this make sense? is one method better than the other in my particular case? is there nothing that can compromise? any suggestions about an alternative for storing and manipulating the data would be most welcome! thank you in advance for your insight and advice!

-SelArom

Hi! I'm not sure which forum to place this in, so if there is a more appropriate one, please move it or let me know and I will repost it there. thanks.

A while back I developed a simple vb.net program for keeping track of rebates. I didn't want to use a database like access or msde because I don't want the overhead in file size and I especially don't want to have to have users install another piece of software in their system just to use my program...

so I implemented it using xml. I made a dataset and put in tables for the stores and the individual rebates. it worked really really well! the only problem is that because it's xml and a dataset, it has to load the entire file into memory when the program loads, and manipluate it in memory and write back to the file as a whole.

see, I like the idea of using a database because it only accesses the informaiton you need for that particular rebate. there is a performance hit because it has to retrieve each time you change rebates/stores, but you would always only be looking at one at a time, so there is no need to have them all in memory.

does any of this make sense? is one method better than the other in my particular case? is there nothing that can compromise? any suggestions about an alternative for storing and manipulating the data would be most welcome! thank you in advance for your insight and advice!

-SelArom

The downside of xml is its memory consuming indeed.
After thinking I can suggest only one thing.
Reduce the size of the xml by trying to split it and not put it in one xml-file.
You can use the filename to mark table and record.
Example: coffeemachine.customers.0000023.xml
Or you a folder to determine the table name.

Downside is you get alot more files.
Goodside is it takes lesser memory when reading one record since you only load
one small xml file.

commented: he he, good to see you here, MMF aka BEO1741 +2
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.