I have seen a lot of topics asking for the choice of a database for a voting mechanism,but my inputs are a bit different. I have an application which contains a GUI in which there can be multiple fields/ radio button or a combination of the above. THe GUI is not fixed. Based on the form submitted, the answer XML is dynamically generated.
Thus if there is a form there can be 10000 different people submitting the same form . and i will be having 10000 different forms(numbers will increase).
I now have the following 2 options. Store every xml as it is in the database ( i have not made the choice of using a relational db or a nosql db like mongodb.) or parse the xml and create tables for every form. THat way the number of tables will be huge.
Now , I have to build a voting mechanism which basically looks at all the xml's that have been generated for a particular form i.e 10000 xml's and extract the answers submitted (Note: the xml is complex because 1 form can have multiple answer elements) and then do a vote to find how many people have given the same answer.
My Questions:
- Should I use a relational db or NOSQL (MongoDB /Redis or similar ones)?
- Do I need to save the xml documents as it is in the db or should I parse it and convert it to tables and save it? Any other approach that I can follow.
I am using JAVA/J2EE for devlepment currenty.