Yes, you could do that. I would still need more details before I could give you the code (and it looks like you need to work out details yourself ), but, yes, I believe DBMan can do what you want.
------------------
JPD
------------------
JPD