Email Notification
Send emails to your customers based on any criteria
 

Print  

Quick Jump to:
Instructions
You can use the Email Notification Action to notify your customers about orders, backorders, special announcements and more. Selections are made using the Report Writer interface so you can select email recipients by almost any criteria.
  1. To run the Email Notification Action click its icon on the Mailware Explorer. Or, click here to open the Email Notification screen.

The following Email Notification screen will appear:

  1. If you have already edited your campaigns you can send them now. Skip to the Send Email instructions below to continue. 
     
    Or,
     
    If you would like to edit or create a campaign select it from the list and click the Edit button on the toolbar.

    Select an item (e.g. Invoice) from the list and click Edit.


     
    Note: Several pre-built campaigns are included in the list. You can select and use any of them you wish. Some included campaigns are:
  • Invoice - Use this campaign to send confirmation notices to your customers who placed orders. This campaign sends an email to all customers who ordered on today's date and have an email address.
     
  • Statement - Lists all outstanding amounts on all invoices for each customer.
     
  • Ship Notification - Use this campaign daily to notify customers that their order has shipped. It includes items shipped and the ship date. Selects all orders shipped on today's date.
      
  • BO Notification - Sends a notice indicating which items ordered are on backorder. Includes the expected date of shipment if you enter this information on the On Order Expected Date field on the Product screen. Selects all orders entered on today's data.
     
  • PO Invoice - Same as the invoice campaign but selects only those orders in the Invoicing tab of the Process Orders action. This allows you to send emails multiple times during the day and only to orders that you have processed.
     
  • PO BO Notice - Same as the BO Notification campaign but selects only those orders in the Backorders tab of the Process Orders action. 
  1. The following dialog will open:

The pre-built campaigns include sample entries that must be changed to match your email settings. You can find these in your email software. For example, in Outlook click Tools>Accounts on the text menu. Click the Mail tab and double click an entry in the list. Your mail host is located under the Servers tab.

Enter your information for the following fields:

  • Email Name - This is the name of the campaign and is for internal use only. You can keep the existing name or change it to one you will easily recognize.
     

  • Mail Host (SMTP) - Your Internet Service Provider (isp) can provide this information or you can find it in your email software. The format is usually smtp.yourisp.com (e.g., smtp.earthlink.net).
     

  • Account Name - This is your email account name used to sign on to your email account. It is frequently your name, your company name or some abbreviation of one of these (e.g., JSMITH439).
     

  • From Email Address - This is your main email address as assigned by your provider (e.g., info@mydomain.com).
     

  • From Name - Enter your company name here. This will be the name your recipients see on the email.
     

  • Reply To Email Address - If you enter an email address here it will be used instead of the From Email Address. This field is optional.
     

  • Subject - This will be seen by your recipients as the title of your email.
     

  • Blind Carbon Copy - Optionally enter an email address here to have a copy of the email sent to that address. The recipient will not see this address on the email.
     

  • Carbon Copy - Optionally enter an email address here to have a copy of the email sent to that address. The recipient will see this address on the email.

  1. Click the Message tab or hold Alt and press N to switch between tabs. Note: the Data tab is covered in the following steps. You do not need to use the Data tab unless you want to edit or create a campaign's selection criteria.

  1. The following screen will appear:

  1. This screen contains the text of your email message. On pre-built campaigns you can simply use the existing text or change it to meet your needs. You can also insert fields from the query that is defined in the Data tab.
     
    Make any text changes you wish to the Header and Footer sections. If you would like to insert fields into any section you can type them in square brackets [ ] or select them from the button. 
     
    For example, to insert the customer's last name into the Header, position your cursor after the [FirstName] field and press the space bar. Then click the button to open the field menu.

Select LastName from the menu that pops up. It will be added to the Header. Your greeting should now look like the following:

You can add any field in the list to any section, however, you will typically add only repeating information in the Detail section (e.g., items from an order). Your main text will appear in the Header and Footer.

  1. If you have data available for the campaign (e.g., the Invoice campaign selects all your orders for Today's date) you can preview your emails.

    Click the button to see a sample list of emails. The following dialog will open:

  1. You can double click the (Memo) field of any email to see a preview of the actual email text. 

    Double click the (Memo) field of a record to see a sample email. The following dialog will open:

  1. This screen previews the text for a specific customer with their data. Emails are text files and may appear differently in individual emails based on fonts used.

    Click the button to close the preview.
     

  2. You will be returned to the Email dialog. Click the button to close it and save your changes. You will be returned to the Email Campaigns screen which you can close with the X in the corner. If you are ready to send your emails proceed to the next step. 
     

  3. You can Send your emails any time. First, open the Email Notification screen as described above and if you have not done so enter your email information (ISP, email address etc). Or, click here to open the Email Notification screen.
     
    Select the campaign you wish to send, make sure you are connected to the Internet then click the Send button.

  1. The following dialog will open:

  1. You can select or deselect any record by double clicking its Send checkbox. You can also check or uncheck all records using the and buttons.

    When you are ready to send emails click the button.
     

  2. As each email is sent its status is updated in the list. When all emails have been sent click the button. Then click the X on the Email Campaign dialog to close it.
     
    Note: A record of each email sent is saved in the EmailArchive.db table. You can see the status of your emails in the following reports:

  1. You can Create your own email campaigns or edit an existing one to change how customers are selected. First, open the email campaign screen as described above. Or, click here to open the Email Notification screen.
     

  2. Select a campaign and click the Edit button, or to create a new campaign click Add button.

  1. Under the Settings tab enter your email information as described above.
     

  2. Next, click the Data tab or hold Alt and press N to switch between tabs.

  1. The following screen will appear:

  1. This screen contains 2 main parts. The top half shows the SQL code that is used to select which customers receive an email and what information is available to be displayed in the email. You can edit it manually or use the report writer interface to create or edit a campaign.
     
    The lower half contains pulldown lists of fields available from the query. These are used to specify which fields are used by the email.
     

  2. If you are creating a brand new campaign the SQL section will be blank. If you are editing a campaign text will appear in this section. If you know SQL you can edit it manually by clicking the checkbox next to "Manually enter SQL". 
     
    You may prefer to use the report writer interface to create or edit your query. To use it click the button. A dialog similar to the following will open.

  1. You can create a query just as you would a report. For help creating reports see the help topic Modifying Reports. You can also load an existing report and edit it for your query. To do so click File>Open Report from the text menu and browse to the Mailware Reports directory (located under your data directory). Select a report and click Open.
     
    Note: Some report functions are not available for email queries. This includes prompts for dates and fields, @functions (Sum, Count etc.), layout page features and field formatting. Also, when adding fields do not include spaces in headers. 
     

  2. When you are finished making changes to your query click File>Save from the text menu (Note: If you load an existing report and make no changes to it you must use File>Save to save the query).
     

  3. Click File>Close Report to exit the report writer dialog. If you have made changes to the query you will receive the following message:

Click Yes when prompted. Note: changes will NOT be made to any report you used to create the query. Changes are only made to the email query, and are stored in the Email.db table in the SavedReport field.

  1. Another prompt will appear as follows:

Click OK to save your query changes.

  1. You will be returned to the Data tab of the email campaign you are editing. You can now select fields in the pulldowns in the lower half of the screen. Fields are as follows:

  • Group By - Use this to select a field by which results for the query will be grouped together. For example, if creating an invoice query group by OrderNo. This will list all items from an order within that order number.
     

  • Email Address Field - Select the field the campaign will use for a mailing address. This is typically the email field from the Customer table. This field is required before you can Preview any results.
     

  • Customer # Field - Select the field that contains the Customer #. This is used to associate the email with a specific customer account. The typical field for this is CustNo from the Customer table. This field is optional, but recommended.
     

  • Order # Field - Select the field that contains the Order #. This is used to associate the email with a specific order. The typical field for this is OrderNo from the Orders table. This field is optional, but recommended.

  1. You can at this point click the button to see the records that will be selected by the query. This preview does not show the actual email. That is available from the Message tab.
     

  2. Click the Message tab or hold Alt and press N to switch between tabs. 


     

  3. Use the instructions above to create your email message. You can type any text you wish into the Header and Footer sections. The Detail section is used for repeating data (e.g., products from an order). Use the Insert Field button to add variables (customer name and information, items orders, prices paid, amounts due etc.).
     
    When you are finished editing your email click the button to save your changes. You can send your emails using the instructions above for Sending Emails.
     

ADVANCED TIP:  You can edit the SQL for the email directly (it is located under the Data tab). Additionally you can add prompts (e.g., Order #, Date Ranges etc.)  for any field using the following syntax:

Mailware can include prompts in the scripts by using parameters with a certain structure.  For instance, this statement would prompt for a date to be entered:

SELECT
  *
INTO
  TEMP_MyTable
FROM
  Orders
WHERE
  OrderDt = :DATE_Please_enter_the_order_date

This will prompt for a date with the text "Please enter the order date:" and
would include in the result table (TEMP_MyTable) the orders that matched the
date entered.

Parameters always start with a colon.  Parameters with the following
prefixes will generate a prompt:

:DATE_
:INTEGER_
:NUMBER_
:CURRENCY_
:TEXT_
:TODAY_  (just like DATE, but defaults to today's date)

You will get a prompt each time the parameter shows up in the SQL.  If you use the same parameter twice, it will still prompt the second time, and a different value may be entered.

 


See Also:
Modifying Reports