cancel
Showing results for 
Search instead for 
Did you mean: 

Import BW master data javascript question

Former Member
0 Kudos

Hi experts,

In BW master datas include "-" symbols. When i use javascript like this, "js:%external%.replace("-";"") its work fine. But when master data is include double "-" symbols ( like TG-43-45) , the result is "TG43-45" . So, dont apply for second "-" symbol.

What is the true js code?

Take it easy...

Accepted Solutions (1)

Accepted Solutions (1)

krishna_priya1
Contributor
0 Kudos

you have to replace all little differently. js:%external%.replace(/-/g ;"") . let me know if it works.

Former Member
0 Kudos

Hi,

Thanx for fast reply, change nothing.

Take it easy..

krishna_priya1
Contributor
0 Kudos

as per the javascript explanation [here|http://www.w3schools.com/jsref/jsref_replace.asp] it should work as expected .

Take it easy..

Answers (1)

Answers (1)

Former Member
0 Kudos

As well as my conversion file like this :

EXTERNAL              INTERNAL                                                FORMULA
 *-*                   js:%external%.replace("-";"")                               

Edited by: BHDRKOCA on Oct 21, 2011 2:50 PM

Edited by: BHDRKOCA on Oct 21, 2011 2:50 PM