on 10-21-2008 6:57 PM
my src structure
<appointment>
<empno> 1 </empno>
<empno>2 </empno>
</appointment>
empno is 0..unbounded.
how do we know how may times this empno element is coming in the source
I have a setempno method and getempno method inside appointment class.
private String[] empno = null;
public void setempno (String o){
empno<i> = o;
}
public String getempno (int i){
return empno<i>;
}
but as i initialized empno[] = null; it is taking null and could not retrive how many empno are coming.
Hi Viswanath
Your requirement is to know how many times the Empno occurs is it ?
You can try using the standard count function in message mapping. This can give you the count of empno.
Thanks
Gaurav
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Iam not using message mapping, iam using java mapping .
my src structure
<appointment>
<empno> 1 </empno>
<empno>2 </empno>
.
.
</appointment>
empno is 0..unbounded.
appointment is 0..unbounded
as I said Iam SAX parser, i have setter and getter methods, to set the values.
what shud be written to capture all the elements under appointment.
private String[] empno = null;
public void setempno (String o){
empno = o;
}
public String getempno (int i){
return empno;
}
you code is incorrect too. You are assigning String to String array.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
can anybody share your thoughts on this please
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.