Go to previous topic
Go to next topic
Last Post 10/9/2008 8:03 PM by  Rod Weir
SQL Script to convert all email addresses in HelpMaster Pro to lower case
 2 Replies
AddThis - Bookmarking and Sharing Button
Author Messages
Rod Weir
HelpMaster development team
Helpdesk Hall of Fame
Helpdesk Hall of Fame
Posts:555
Points:1017


--
10/9/2008 3:17 PM

    Hello everyone,

    It seems that when the v8 Email Manager looks for a match between an incoming email and and email in the HelpMaster Pro database, it does a case sensitive search.  This means that if the case is different in the email to what it is in the database, a match will not be established.

    This oversight will be corrected in a future release of the Email Manager.  As a work-around, you may like to run an SQL Script against your database to update all email addresses to lower case.  As usual, please make a backup before doing any sort of bulk update, and do not alter this script in any way.

    Here's the script. HelpMaster Pro v7.5, v8 and v9 only.

     

    ALTER Table tblEntityValues Disable Trigger tblEntityValues_UpdateTrigger

    Update tblEntityValues
    Set DetailValue = Lower(DetailValue)
    FROM tblEntityValues INNER JOIN
    tblSystemCodes ON tblEntityValues.SystemCodeLink = tblSystemCodes.PKId INNER JOIN
    tblSystemCodeCategories ON tblSystemCodes.CategoryLink = tblSystemCodeCategories.PKId
    WHERE (tblSystemCodeCategories.SystemID = 'sys_email')

    ALTER Table tblEntityValues Enable Trigger tblEntityValues_UpdateTrigger

     

    Best regards,

     

    Rod

    HelpMaster development team
    Check out the HelpMaster roadmap
    helpdesk@ntsolutions.com.au
    New Member
    New Member
    Posts:3
    Points:7


    --
    10/9/2008 7:59 PM
    I was thinking about this a bit more and I thought if you update helpmaster pro database to show all email addresses to lower case and someone sends you an email but has some characters in upper case, would you not still have the same issue of emails not being processed by the email manager?

    Cheers,
    Alex
    Rod Weir
    HelpMaster development team
    Helpdesk Hall of Fame
    Helpdesk Hall of Fame
    Posts:555
    Points:1017


    --
    10/9/2008 8:03 PM
    Good thinking Alex,

    The code in HelpMaster Pro already converts the incoming email address to lowercase before doing a comparison with the value stored in the HMP database, so it's already taken care of. The bit of code that needed to be updated (in the HMP source) was the other side of the comparison where it wasn't adjusting the database value, hence the SQL script above.

    We've already fixed this issue in code and a maintenance release shoud be available soon.

    Hope this helps,

    Best regards,

    Rod

    HelpMaster development team
    Check out the HelpMaster roadmap


    ---