Mr. Jison,
How are you? I've read through your thread and it does sound familiar. We've done this for a harware store, using VB6 and MSDE.
May I suggest that you just create a function to do this. It will simplify this the whole thing. When I say function I mean VB or VFP function and not SQL function.
Best regards,
Martin
Shit happens!!!