in reply to Different Ways to Do It

You will want to use a RDBMS. MySQL, since you have it, sounds like a good choice.

As for wanting to deal with this before inputting data ... that's a straw man. It is the matter of a few minutes to take your old reading routine and your new writing routine and hook them together. Data and algorithms should be dealt with separately.

------
We are the carpenters and bricklayers of the Information Age.

Then there are Damian modules.... *sigh* ... that's not about being less-lazy -- that's about being on some really good drugs -- you know, there is no spoon. - flyingmoose

I shouldn't have to say this, but any code, unless otherwise stated, is untested