wood burning stoves*
The moose likes Beginning Java and the fly likes Fail to construct descriptor: empty Object name Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Fail to construct descriptor: empty Object name" Watch "Fail to construct descriptor: empty Object name" New topic
Author

Fail to construct descriptor: empty Object name

Vikram Gosain
Greenhorn

Joined: Jun 02, 2009
Posts: 25
Hi
When I execute a java stored proc

I get the exception


But when I initialize the everything runs fine. I am not able to understand why?Could anyone please help me with this.?


-Vikz
Michael Krimgen
Ranch Hand

Joined: Jul 08, 2012
Posts: 35
Hi Vikram,

The String is not initialized. Only class variables are initialzed with the default values, local variables are not.

If you do not want to initialze your String with a blank, you should do the following:

Winston Gutkowski
Bartender

Joined: Mar 17, 2011
Posts: 7484
    
  18

Vikram Gosain wrote:I get the exception...

Vikram,

Please don't put enormously long lines inside code tags. I've broken them up for you this time, but please re-read the UseCodeTags page thoroughly.

Thanks

Winston

Isn't it funny how there's always time and money enough to do it WRONG?
Articles by Winston can be found here
Vikram Gosain
Greenhorn

Joined: Jun 02, 2009
Posts: 25
Hello Winston
I will keep this in mind. Thanks for the information

Michael
Could you please elaborate more on the error? Why am i getting this specific exception when i intialize the string to blank and why I dont get any error when I initialise the string to null. Is it related to StoredProc() api of Spring JDBC template?
Vikram Gosain
Greenhorn

Joined: Jun 02, 2009
Posts: 25
Trying my luck again..

Can anyone please explain the reason why this happens?
 
 
subject: Fail to construct descriptor: empty Object name
 
Similar Threads
JDBC Related Question
How to call StoredProcedure with mixed input data types?
Spring-RowMapper-DB2-Stored Procedure
RowMapper & Stored Proc @ DB2
trouble passing array to stored procedure in spring HELP