• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

how to loop through queries for different time zones

Guest
Apr 21, 2013 Apr 21, 2013

Copy link to clipboard

Copied

I am working on a script that will send out daily messages to an individual who has subscribed to a particular company’s daily message.

The subscribers table has:

  • Firstname
  • Email
  • Company ID
    Delivery method
    • Desktop
    • Phone  

I have set up a query that pulls the subscribers information to:

  1. Determine which business
    1. Which layout to use (contact_id)
    2. Determines time zone
      1. Phones will be sent at a later time than the desktop
  2. Which version to send:
    1. Desktop with all graphics
    2. Phone with graphics removed

                               

I can use a cfloop to send the message out every morning, I just don’t know how to efficiently send out the message by the different time zones.

Each time zone will have 2 diff times:

  1. 5:00am for the desktop
  2. 8:00am for the phones

Any suggestions would be helpful.

Views

834

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 21, 2013 Apr 21, 2013

Copy link to clipboard

Copied

Schedule your job for every possible hours and send the appropriate emails each time.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Apr 21, 2013 Apr 21, 2013

Copy link to clipboard

Copied

You can schedule a job for each time zone..

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Apr 22, 2013 Apr 22, 2013

Copy link to clipboard

Copied

LATEST

Thanks Dan and Meensi for replying. I thought of doing something like this, I was afraid that scheduling 8 jobs over 4 hours may tax the server. It's not like I have a lot of emails to send out yet, I don't want to have to update the script too often.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation