1 Reply Latest reply: Aug 10, 2014 3:41 PM by user10407165 RSS

    String Functions in Oracle GoldenGate


      Hi All,


      I have a question regarding the string functions in Oracle GoldenGate. I want to extract a substring from a string and the only function I can see is @STREXT for this I have to provide the begin and end position explicitely.

      for eg;

      source string - abcdefg

      i want to extract - defg


      My question is, is there a function similar to Right() as in Oracle Db, where in it returns the specified number of rightmost characters


      Best Regards,


        • 1. Re: String Functions in Oracle GoldenGate

          Hi Partha,

          Here is a document that lists all available GoldenGate @ functions. I don't think there is one that works the same as Right().


          But you can piece such function together using @if, @strext and @strlen:

          @if( @strlen(column)<= x , columns, @strext( column , @strlen(column)-x. @strlen(column))

          where x is amount of characters you want to keep.

          Also you can call oracle function using SQLEXEC syntax:

          map souce_table, target target_table, &

          SQLEXEC(ID get_right, QUERY "select right(:id,x) val from dual"), &

          COLMAP ( column = @getval(get_right.val) );


          Hope this helps