Skip to content
Snippets Groups Projects
Closed SQL error: role_id is treated as a number instead of string in CRM/Event/ActionMapping.php at line 152
  • View options
  • SQL error: role_id is treated as a number instead of string in CRM/Event/ActionMapping.php at line 152

  • View options
  • Closed Issue created by alainb

    At line 152 of CRM/Event/ActionMapping.php we find:

    $query->where("e.role_id IN (#recipList)") ->param('recipList', \CRM_Utils_Array::explodePadded($schedule->recipient_listing));

    This generates the SQL error "Truncated incorrect DOUBLE value" when a participant has multiple roles.

    role_id is a varchar, so quotes are missing. Then I think it should be LIKE instead of IN. I don't know the best way to fix this code in order to make it work in all situations. But I can help testing the solution.

    You can recreate the error by giving a participant multiple roles and creating a scheduled reminder that would select that participant.

    Linked items ... 0

  • Activity

    • All activity
    • Comments only
    • History only
    • Newest first
    • Oldest first
    Loading Loading Loading Loading Loading Loading Loading Loading Loading Loading