Hi Venu,
For the Input given in your previous post, the output can be achieved using the UDF as follows:
public String calculate1(String var1, String var2, Container container) throws StreamTransformationException{
String temp = "";
if(var2.length() > 0)
for(int i=0; i<var2.length();i++)
temp = temp+var1;
var1 = temp;
return var1;
}
Check if it helps. We can build on this UDF as per your requirement.
Regards,
Azhar
Message was edited by: Azhar Shaikh