Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Message Mapping activation error-Source code has syntax errors in UDF

Hi all,

I wrote a small UDF for sum of 2 numbers:

import

udf.*

public String getsum(String a, String b, Container container) throws StreamTransformationException{

int c = Integer.parseInt(a);

int d = Integer.parseInt(b);

int e = packageDemo.getSum(c,d);

return e+"";}

In imported archives, i imported pack.jar

In D:\udf , I have packageDemo.java, packageDemo.class, aii_map_api.jar, pack.jar(has the other 3)

packageDemo.java :-

package udf;

public class packageDemo{

public static int getSum(int a,int b)

{

int c= a+b;

return c;

}}

Did i miss anything?? Icant activate message mapping for 2 errors:-

1.package udf does not exist

2.Function getsum, Line 3:

cannot find symbol symbol : variable packageDemo location: class com.sap.xi.tf._xml_mm_int e = packageDemo.getSum(c,d); ^Note: /usr/sap/P7R/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Mapd4214d3099dc11dd9470001d090e4bbe/source/com/sap/xi/tf/_xml_mm_.java uses or overrides a deprecated API.Note: Recompile with -Xlint:deprecation for details.Note: /usr/sap/P7R/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Mapd4214d3099dc11dd9470001d090e4bbe/source/com/sap/xi/tf/_xml_mm_.java uses unchecked or unsafe operations.Note: Recompile with -Xlint:unchecked for details.2 errors

Edited by: NagaDurga Nannapaneni on Oct 16, 2008 1:07 PM

Not what you were looking for? View more on this topic or Ask a question