View Issue Details

This bug affects 1 person(s).
 8
IDProjectCategoryView StatusLast Update
15924Bug reportsSurvey participants (Tokens)public2020-06-05 06:17
Reporteracran Assigned To 
PrioritynoneSeverityminor 
Status closedResolutionfixed 
Product Version4.1.7 
Summary15924: Can not send invitations to imported participants where emailstatus IS NULL
Description

After importing participants from CSV with an empty or omitted emailstatus trying to send invitation e-mails ends up with an error message although all listed criteria are actually fulfilled:

There were no eligible emails to send. This will be because none satisfied the criteria of:

  • having a valid email address
  • not having been sent an invitation already
  • not having already completed the survey
  • having an access code
  • having at least one use left
Steps To Reproduce
  1. create a new survey
  2. add a participants table
  3. import participants via a CSV without a "emailstatus" column (see attached example)
  4. generate access tokens
  5. go to "send email invitation"
  6. disable the "Bypass participants with failing email addresses:" checkbox (since the emailstatus is empty and not "OK")
  7. click "send invitations"
    => error message appears
Additional Information

I figured that after clicking edit on a affected particpant and saving it without doing any changes the invitations do work. Looking at the database contents I found that the problem is that after importing the "emailstatus" column is set to NULL. Manually editting and saving "wihtout changes" sets it to an empty string though and after this it works.

This issue is related to 15772 and 15823

TagsNo tags attached.
Attached Files
participants.csv (49 bytes)   
firstanme,lastname,email
John,Doe,jd@example.net
participants.csv (49 bytes)   
Bug heat8
Complete LimeSurvey version number (& build)4.1.7 10454b9ffd90dd23c1673253199051a145dc97f9 (current GitHub master)
I will donate to the project if issue is resolvedNo
Browser
Database type & versionMySQL 5.7.29
Server OS (if known)
Webserver software & version (if known)
PHP Version7.2.24

Users monitoring this issue

There are no users monitoring this issue.

Activities

acran

acran

2020-02-27 11:18

reporter   ~56231

Submitted a Pull Request: https://github.com/LimeSurvey/LimeSurvey/pull/1395

guest

guest

2020-05-26 15:00

viewer   ~58039

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=29993

DenisChenu

DenisChenu

2020-05-26 15:58

developer   ~58043

Thank you :)

lime_release_bot

lime_release_bot

2020-06-05 06:17

administrator   ~58186

Fixed in Release 4.2.6+200602

Related Changesets

LimeSurvey: master 5fc29f43

2020-05-26 15:00:45

acran


Committer: GitHub Details Diff
Fixed issue 15924: Can not send invitations to imported participants where emailstatus IS NULL (#1395)

Dev: although the WHERE condition "emailstatus <> 'OptOut'" *intuitively* should match everything that is not equal to "OptOut" it actually does *not* match NULL values in MySQL since it is not NULL-safe.

Dev: This is related to 15772 and 15823 since emailstatus should not be NULL in the first place.
Affected Issues
15924
mod - application/controllers/admin/tokens.php Diff File

Issue History

Date Modified Username Field Change
2020-02-27 10:59 acran New Issue
2020-02-27 10:59 acran File Added: participants.csv
2020-02-27 11:18 acran Note Added: 56231
2020-05-26 15:00 acran Changeset attached => LimeSurvey master 5fc29f43
2020-05-26 15:00 guest Note Added: 58039
2020-05-26 15:58 DenisChenu Note Added: 58043
2020-06-05 06:17 lime_release_bot Note Added: 58186
2020-06-05 06:17 lime_release_bot Status new => closed
2020-06-05 06:17 lime_release_bot Resolution open => fixed