You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

How should I format the phone number in sql?

HOW CAN I FORMAT THIS QUERY AS '+55 111 222 33 11'

SELECT CASE

      WHEN SUBSTR (LTRIM (RTRIM (PPH.SEARCH_PHONE_NUMBER)), 1, 3) = '+55' THEN LTRIM (RTRIM ((PPH.SEARCH_PHONE_NUMBER))) WHEN SUBSTR (LTRIM (RTRIM (PPH.SEARCH_PHONE_NUMBER)), 1, 2) = '55' THEN  '+' || LTRIM (RTRIM (PPH.SEARCH_PHONE_NUMBER)) ELSE  '+55' || LTRIM (RTRIM (PPH.SEARCH_PHONE_NUMBER))  END

FROM PER_PHONES PPH

Thank you

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!