Topic
  • 1 reply
  • Latest Post - ‏2013-12-12T00:50:36Z by OpherB
Goud2013
Goud2013
13 Posts

Pinned topic how to get format xxx-xxx-xxxx for a telephone number in cog 10.1.1 reports

‏2013-12-11T22:56:57Z |

Hi All,

Iam trying to convert char into telephone format i.e xxx-xxx-xxxx in cognos 10.1.1 report studio.Iam using DB2 database.Any help would be appreciated.

 

In my database telephone dispalys xxxxxxxxxx defined as Char (10).

 

Thanks in advance...

 

  • OpherB
    OpherB
    664 Posts

    Re: how to get format xxx-xxx-xxxx for a telephone number in cog 10.1.1 reports

    ‏2013-12-12T00:50:36Z  

    Should be something like this:

    substring ([Phone],1,3) +'-'+ substring([Phone],4,3) +'-'+ substring([Phone],8,4)

    Good luck,
    Opher