General discussion

Locked

what is causing this java error?

By shimshai ·
I have imported several tables of data into an sql server db with an html interface from another DB using odbc.
All the tables seem to work fine except when i try to view locations.
I then get the following error page:

Unexpected Exception
------------------
The exception is :- java.lang.NullPointerException
at psdi.app.location.Location.isStore(Location.java:604)
at psdi.app.location.Location.init(Location.java:161)
at psdi.mbo.MboSet.generateMboInstance(MboSet.java:1363)
at psdi.mbo.MboSet.fetchMbos(MboSet.java:1560)
at psdi.mbo.MboSet.getMbo(MboSet.java:1289)
at psdi.mbo.MboSet.isEmpty(MboSet.java:2726)
at psdi.jsp.beans.MboSetBean.isEmpty(MboSetBean.java:2843)
at psdi.jsptags.InputTagSupport.gridTagSupportWriter(InputTagSupport.java:403)
at psdi.jsptags.GridTagSupport.doEndTag(GridTagSupport.java:295)
at jsp_servlet._jsp._app._location.__main._jspService(__main.java:1392)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:2546)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2260)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)

This conversation is currently closed to new comments.

6 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

by josef.scherer In reply to what is causing this java ...

Hi

Could you submit some code, s.t. someone can judge, whether one of the Location objects is null?

Josef

Collapse -

by sbockelman In reply to what is causing this java ...

The error is caused by an attempt to access a property or call a method on an object reference that does not currently point to any valid object instance. This error is in the source code on line 604 of the file, Location.java.

How do I know this?
And why can't I tell you more?

1. That's exactly what the stack-trace/error message you included says.

2. You didn't include enough information to solve the problem.

I suggest asking a Java developer at your location to help you debug the JSP page that is failing.

Collapse -

by georgehsnyder In reply to what is causing this java ...

if you go to line 604 of Location.java you will probably find a loop (for or while). You appear to be trying to process beyond the end of your data array. Maybe you did not initialize it to a large enough size or you are up against the old 'off by one' problem. Create a DEBUG class that opens a file and writes your data into it. Pass each element of your data into the debug class then look at the file to see where things are going bad.

Collapse -

by debuggist Staff In reply to what is causing this java ...

Obviously, you're trying to access something that is null. Could you supply the source code that is throwing the exception?

Do you have the source code for psdi.app.location.Location?

Collapse -

by debuggist Staff In reply to

What was the answer to this question?

Collapse -

by ms_anand_babu In reply to what is causing this java ...

Probably u might've used a select query and tried to display the query results. U would've accessed the recordset when there is nothing returned to it out of execution of the query. Query result may be nothing.

Back to Web Development Forum
6 total posts (Page 1 of 1)  

Related Discussions

Related Forums