When I am getting the result from the DB2 and trying to set to this attribute noOfLocations
I am getting the following error.
Method "setNoOfLocations" with signature "(Ljava/lang/Integer;)V" is not applicable on this object
Following code shows the problem.
I am using rs to set the value.
packDO.setNoOfLocations(rs.getInt("NO_LOC_PKG"));
and
rs.getInt("NO_LOC_PKG") is returning 0
and
NO_LOC_PKG is of datatype Integer in the DB
and noOfLocations
type with setter method is,
private Integer noOfLocations;
public void setNoOfLocations(Integer noOfLocations) {
this.noOfLocations = noOfLocations;
}
The error message you posted suggests that it's a build-related issue, as compiler and runtime errors don't generally describe methods by their signatures.
Make sure that your build is up-to-date and that the source available to your debugger matches the source of the binary you are running.
Depending on your build system, issues could result from previous partial builds, unexpected timestamps on files, copying/moving files, a crashed IDE, a quirky build system, etc.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With