Tuesday, August 29, 2006

How to do A/B split testing in JangoMail

It is very easy to conduct an A/B split test in JangoMail.

Using JangoMail Groups

If you are storing your e-mail lists in JangoMail Groups, you simply need to send one e-mail to one half of your Group and the second e-mail to the second half of your Group. You can easily split your Group in half using the "Filter and Send" feature.

1. Click the "Filter and Send" button.

2. Switch to the "Advanced Query Editor".

3. In the yellow "Tips" area, click link for "A/B split testing". This will populate the SQL SELECT and WHERE clauses.

4. Click the "Filter Members Now" button.

Now, JangoMail is prepared to send to half of your JangoMail Group.

After you send this e-mail, you may want to send a varying version to part "B" fo your Group. This step is very simple. This time you will NOT start in the "Filter and Send" section. Just go to the "Send E-mail" section, elect to send the e-mail to the entire Group in the Group selection box, but then down below, under "Don't send to recipients of these past e-mailings:", choose the e-mailing that you previously sent to part "A" of your Group.

This will filter out everyone that received e-mailing "A", thereby sending to only the second half of your Group.

Using an External Database Connection

If you are using JangoMail to pull in e-mail recipient data in real-time from an external database, then you need only write the appropriate SQL query to pull in only half of your records. For example, if your e-mail recipient data is stored in the table "Contacts", the SQL query would be:


If your database does not support the "percent" designation with the TOP keyword, then you can manually specify the half-count of your table. If your table has 5,000 records in it, you could use:

SELECT TOP 2500 * FROM Contacts