-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Postgresql hibernate problem - could not insert
PostPosted: Wed Feb 14, 2007 2:24 pm 
Newbie

Joined: Wed Dec 27, 2006 2:25 am
Posts: 9
Location: Chennai-India
Hi all!,

i have been developing a web application using struts-hibernate concept with postgresql as database., (Postgres- 7.3.2, Hibernate- 2.0, MyEclipse - 3.1.2)

When i insert the value the following error occurs,

root cause

java.lang.ArrayIndexOutOfBoundsException: 1
org.postgresql.core.QueryExecutor.sendQuery(QueryExecutor.java:143)
org.postgresql.core.QueryExecutor.execute(QueryExecutor.java:65)
org.postgresql.jdbc1.AbstractJdbc1Connection.ExecSQL(AbstractJdbc1Connection.java:451)
org.postgresql.jdbc1.AbstractJdbc1Statement.execute(AbstractJdbc1Statement.java:281)
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:48)
org.postgresql.jdbc1.AbstractJdbc1Statement.executeUpdate(AbstractJdbc1Statement.java:179)
org.postgresql.jdbc1.AbstractJdbc1Statement.executeUpdate(AbstractJdbc1Statement.java:165)
org.postgresql.jdbc2.AbstractJdbc2Statement.executeBatch(AbstractJdbc2Statement.java:80)
org.hibernate.jdbc.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:57)
org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:174)
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:226)
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:136)
org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:274)
org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27)
org.hibernate.impl.SessionImpl.flush(SessionImpl.java:730)
org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:324)
org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:86)
com.etm.manager.DistrictLoginUserManager.saveDistrictLoginUser(DistrictLoginUserManager.java:162)
com.etm.struts.action.DistrictLoginEditAction.saveDistrictLogin(DistrictLoginEditAction.java:60)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:585)
org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.java:280)
org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:216)
org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:484)
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:274)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


thanks in advance,


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 14, 2007 10:27 pm 
Newbie

Joined: Wed Jun 21, 2006 2:25 pm
Posts: 15
there is hardly any information out here and I am sure no one would be able to help out. What is the mapping and what are you exactly trying to do. The answer could be in so many places. You need to provide additional context

anand raman


Top
 Profile  
 
 Post subject: Postgresql hibernate problem - could not insert
PostPosted: Thu Feb 22, 2007 8:27 am 
Newbie

Joined: Mon Feb 19, 2007 6:31 am
Posts: 12
Hi

Can you post your hibernate.cfg.xml and also your /hbm.xml? also post your java class that has your session creation.

the problem could be here. i'll have to look at these files.

Avesh


Top
 Profile  
 
 Post subject:
PostPosted: Thu Feb 22, 2007 2:26 pm 
Regular
Regular

Joined: Wed Aug 25, 2004 7:40 pm
Posts: 65
It doesn't seem to be a PostgreSQL problem nor Hibernate's from your error stack messages. Check your own code to see any possibility of out of bound error in an array.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.