in reply to how to speed the mail process?
Yes, I know it's pseudocode, but:
Your prepare statement should be outside the loop.
It is good to avoid select * in code as the schema may change underneath you.
You may want to throw a sleep SOME_INTERVAL into your loop to ease the load on your database or add an option to let the database admin tune as load warrants. Do you have passes through the database that come up empty?
Setting mark should be contingent on the success of send_customer_mail in handing off the message to a MTA.
Be well,
rir
|
|---|