If you are using the local format (e.g.0123456789 format) for Mobile number to store then you can set up another phone field in which you will save a copy of Mobile number from the mobile field in the required format. We can use this new phone field to look-up that object record with incoming messages.

Please follow the steps below to achieve the same individually for each object-:

    • Create new custom field of data type "Phone" say “International Number” as the field name.

    • Download the records which has mobile number starting with “04” with Data Loader.

    • then update all the record's "International Number" field with the International mobile numbers (i.e. change local numbers “0412345678” into format as 61412345678) in column from downloaded CSV file.

    • then uploaded that file to update the "International Number" field with the help of Data Loader/workbench for existing records.

    • Now you have International format number in "International Number" field for existing record.

    • For the records which will be getting created in future, you need to setup the workflow rule on creation of that record and setup evaluation criteria as "Mobile" field not equals to blank

    • then set up workflow action as “field update”, select field "International Number" for updation.

    • select formula evaluates to true option and Set up the formula value for that updation as similar to below (This formula is for Australian numbers)--> IF(LEFT( MobilePhone , 2) = "04",TRIM ( "61" & TRIM(RIGHT(MobilePhone, LEN( MobilePhone )-1 ))), MobilePhone)

    • save and activate the workflow rule.

    • Now your all records existing and new one, will store mobile number in international format in “International Number” field.

    • We need to change the Look-up setting mobile reference field to "International Number" field.

    • To do the same -:

    1. Goto SMS Settings-->Action on Incoming SMS-->Look-up configuration to do the same

    2. delete existing Lookup configuration records.

    3. setup New look-up configuration for those object again. Here the only change will be that you need to select Mobile field Name as "International Number" instead of older mobile field having local mobile number format.

I hope this helps you. Let me know if you need any information further.