NullPointerException « Exception « JPA Q&A





1. Hibernate fails with NullPointerException in EntityTuplizerFactory.constructTuplizer? Why?    stackoverflow.com

I have a problem when I try to instantiate Hibernate and connect with a MySQL database (see error message below). Curiously enough the connection works fine using the exact same hibernate.cfg.xml ...

2. null pointer exception at org.hibernate.tuple.AbstractEntityTuplizer.createProxy    stackoverflow.com

I am using hibernate 3.2 with struts 1.2 framework here is the details of versions hibenate3.2,asm-2.2.3,cglib-2.1.3 I got this exception when i m trying to load the object I am using this ...

3. java.lang.NullPointerException in a sample program of Hibernate    stackoverflow.com

i am try to run a sample application of hibernate, it give me a error on run time:

log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
log4j:WARN Please ...

4. Hibernate problem -- NullPointerException    stackoverflow.com

I'm getting a NullPointerException in the following Hibernate code. I've marked the line with the problem. Can anyone help?

public List<Bulletin> searchForBulletins(String searchTerms) {
    StringTokenizer search = ...

5. Hibernate related object not hydrated    stackoverflow.com

Please see code below. DeviceDAO, Device, and Mobileuser are hibernate generated objects. the process works until i get to the second "if" conditional where I call mobileUser.getPin(). The problem is that ...

6. createEntityManager() gives NullPointerException    stackoverflow.com

I'm getting this stack trace when I deploy my hibernate app

14:49:30,201 ERROR [com.mycompany.myapp.common.persistence.HibernateUtil] (MSC service thread 1-11) Initial SessionFactory lookup failed.: java.lang.NullPointerException
at org.hibernate.engine.transaction.internal.jta.JtaStatusHelper.getStatus(JtaStatusHelper.java:72) [hibernate-core-4.0.0.Beta1.jar:4.0.0.Beta1]
at org.hibernate.engine.transaction.internal.jta.JtaStatusHelper.isActive(JtaStatusHelper.java:114) [hibernate-core-4.0.0.Beta1.jar:4.0.0.Beta1]
at org.hibernate.engine.transaction.internal.jta.CMTTransaction.join(CMTTransaction.java:149) [hibernate-core-4.0.0.Beta1.jar:4.0.0.Beta1]
at org.hibernate.ejb.AbstractEntityManagerImpl.joinTransaction(AbstractEntityManagerImpl.java:1197) [hibernate-entitymanager-4.0.0.Beta1.jar:4.0.0.Beta1]
at org.hibernate.ejb.AbstractEntityManagerImpl.postInit(AbstractEntityManagerImpl.java:170) ...

7. Hibernate NullPointerException    coderanch.com

I apologise for posting it wrong. It is Configuration cfg = new Configuration().configure(); I tried running it as a standalone program and still getting the following stack trace: java.lang.NullPointerException at com.hibernate.test.Runner.update(Runner.java:49) at com.hibernate.test.Runner.main(Runner.java:19) The code is below: package com.hibernate.test; import net.sf.hibernate.HibernateException; import net.sf.hibernate.MappingException; import net.sf.hibernate.SessionFactory; import net.sf.hibernate.Session; import net.sf.hibernate.cfg.Configuration; import com.hibernate.beans.*; import java.sql.SQLException; public class Runner { public Runner() { } ...

8. NullPointerException when trying to run the Hibernate Example    coderanch.com

Hi, I am new to Hibernate. I downloaded the hibernate 3.0.5 and followed the steps to run the example that comes with the hibernate installation. I configured the example to run for Oracle 9i database. When I try to run the example by typing "build eg" I get NullPointerException when it tries to create the Sample test Data. I could see ...

9. NullPointerException in hibernate    coderanch.com

i am new to hibernate.so i am doing tutorials this is my config.xml file com.mysql.jdbc.Driver jdbc:mysql://localhost/hibernatetutorial root 10 true org.hibernate.dialect.MySQLDialect update this is my mapping xml file ...





11. NULL Pointer Exception in Hibernate    coderanch.com

12. Null Pointer Exception :( :(    forum.hibernate.org

Newbie Joined: Sun Dec 27, 2009 4:52 am Posts: 4 Hi all, Im getting the following null pointer exception when i try to persist an object using Hibernate. Im using Spring's hibernate templates for this. below i have posted the stack trace i got and i have posted the source files and the mapping file. Its a big help if anyone ...

13. null pointer exception    forum.hibernate.org

i am new to hibernate i try outer join query in hibernate. but it is showing null pointer exception which is in the line ==> Iterator ite = query.list().iterator(); please send the reply to me how i can solve this error.it is very urgent. i send the full stack trace of my exception. 11:31:44,562 INFO Environment:456 -11:31:44,562 INFO Environment:469 -11:31:44,562 INFO ...

14. re:null pointer exception    forum.hibernate.org

this is my sql query see what wrong in this and reply to me it is very urgent.i have to complete this task i am struggling in this exception for the past two days. i have try the outer join query. String sql_query = " select empdet.firstname,empdet.city,empmail.firstname,empmail.email FROM sample.EmpDetail empdet left outer join fetch sample.Employee empmail where empdet.Empid = empmail.Empid"; advance ...

15. null pointer exception    forum.hibernate.org

Beginner Joined: Fri Feb 26, 2010 8:23 am Posts: 29 i have try with association as u said but i am getting the same null pointer exception. once again i send the modified outer join query with the foreign key mapping. help me it is very urgent.where i have done the mistake my main class package simple; import org.hibernate.Query; import org.hibernate.MappingException; ...

16. null pointer exception    forum.hibernate.org

Beginner Joined: Fri Feb 26, 2010 8:23 am Posts: 29 i have try with association as u said but i am getting the same null pointer exception. once again i send the modified outer join query with the foreign key mapping. help me it is very urgent.where i have done the mistake my main class package simple; import org.hibernate.Query; import org.hibernate.MappingException; ...





17. null pointer exception    forum.hibernate.org

18. null pointer exception    forum.hibernate.org

19. null pointer exception    forum.hibernate.org

20. null pointer exception    forum.hibernate.org

21. null pointer exception    forum.hibernate.org

thank u for ur reply but i still got the same exception could u please point out in the code where i had done the mistake. it is my humble request to u. actually key column in the bag means it specifies foreign key. reply me soon i am waiting for u. i already send the code to u.

22. null pointer exception    forum.hibernate.org

please help me i have to finish my task i need help from u it is very urgent. sorry for disturbing you this is the last i have to do. once again i send the code i am using unidirectional foreign key mapping association in that i am trying left outer join query first i send the query select emp.firstname,Insurance.InsuranceName,Insurance.InvestmentAmount FROM ...

23. NullPointerException on AbstractLockUpgradeEventListener    forum.hibernate.org

Hi, I'm using hibernate-core 3.3.2.GA, hibernate-annotations 3.4.0.GA, hibernate-entitymanager 3.4.0.GA with javax.persistence persistence-api 1.0. Occasionally, I get the following the stack-trace when I'm running many loads one after the other: Code: Caused by: java.lang.NullPointerException at org.hibernate.event.def.AbstractLockUpgradeEventListener.upgradeLock( AbstractLockUpgradeEventListener.java:60) at org.hibernate.event.def.DefaultLoadEventListener.loadFromSessionCache (DefaultLoadEventListener.java:488) at org.hibernate.event.def.DefaultLoadEventListener.doLoad(DefaultLoadEv entListener.java:378) at org.hibernate.event.def.DefaultLoadEventListener.load(DefaultLoadEven tListener.java:165) at ...

24. java.lang.NullPointerException in hibernate    forum.hibernate.org

Hibernate seems to be keeping the details behind my problem a secret, not sure how to uncover some helpful debugging info. Anyone know how to get more info than this out of hibernate (IMHO it should provide this by default) ? I am really looking more for suggestions on how to get hibernate to display more useful information to be able ...

25. Null Pointer Exception in Hibernate Template    forum.hibernate.org

I am working on application which contains Struts and hibernate and i am trying to use HibernateTemplate Getting exception which is given below 17:35:56,341 DEBUG ExceptionCatcher:141 - Attempting to handle a thrown exception 17:35:56,341 DEBUG ActionCommandBase:49 - Executing org.apache.struts.chain.commands.servlet.ExceptionHandler 17:35:56,341 DEBUG AbstractExceptionHandler:77 - See if actionConfig ActionConfig[cancellable=false,path=/searchc mmand,validate=true,input=/jsp/search.jsp,name=SearchForm,scope=session,type=org.ird.ivl.presentation.SearchCo mand has an exceptionConfig for java.lang.NullPointerException 17:35:56,341 DEBUG ActionConfig:940 - findException: look locally ...

26. HibernateTemplate (NullPointerException)    forum.hibernate.org

Basically, I'm doing a very simple web application using Hibernate, Spring and Struts (using annotations). I have created one table into my DataBase where I would like to put and request the information. I have configured all the XML files like applicationContext.xml, hibernate.cfg.xml, hibernate.properties and also, I have programmed java classes. I have this classes: Alumno.java (this is an entity class) ...

27. NullPointerException when using JWS in Ubuntu    forum.hibernate.org

Newbie Joined: Fri Jan 14, 2011 11:53 am Posts: 1 I have a problem I cannot solve or find a possible solution by searching. I'm developping a J2SE app using Netbeans, everything works fine, now I'm trying to launch it using Java Web Start so I can deploy it on an apache web server and update ir regulary, because It is ...

29. Metamodel NullPointerException Problem    forum.hibernate.org

If someone could assist me in putting me back on track. I have a slight problem with using the Metamodel in helping with building queries. Here are the relevent code snippets: User.java Code: package votify.domain; @Entity @Table(name="VOTE_USER") public class User implements Serializable { public static final String PROP_NAME = "name"; public static final ...

30. Hibernate throws NullPointerException in EntityVerifyVersion    forum.hibernate.org

Newbie Joined: Wed Apr 27, 2011 10:15 am Posts: 2 In a webapplication with Hibernate, I'm using a standard interceptor to create and commit my transactions. However, I'm getting a NullPointerException when the transaction is committed. The error hints to bad session-management, but I don't know why. I can only find very little information about this particular error. Can anybody help? ...

31. NullPointerException org.hibernate.type.EntityType.isEqual    forum.hibernate.org

Newbie Joined: Wed Jul 19, 2006 4:13 am Posts: 6 We are using the following: hibernate-c3p0-3.6.3.Final.jar hibernate-commons-annotations-3.2.0.Final.jar hibernate-core-3.6.3.Final.jar hibernate-entitymanager-3.6.3.Final.jar hibernate-jpa-2.0-api-1.0.0.Final.jar mysql-connector-java-5.1.12.jar MySQL Server 5.5.9 Sometimes, when starting our application we get a NullpointerException. This always happens at the very beginning, after executing one of the first queries. To solve the problem it is usually sufficient to start the program again. Sometimes ...

32. createEntityManager() gives NullPointerException    forum.hibernate.org

I'm getting this stack trace when I deploy my hibernate app Code: 14:49:30,201 ERROR [com.mycompany.myapp.common.persistence.HibernateUtil] (MSC service thread 1-11) Initial SessionFactory lookup failed.: java.lang.NullPointerException at org.hibernate.engine.transaction.internal.jta.JtaStatusHelper.getStatus(JtaStatusHelper.java:72) [hibernate-core-4.0.0.Beta1.jar:4.0.0.Beta1] at org.hibernate.engine.transaction.internal.jta.JtaStatusHelper.isActive(JtaStatusHelper.java:114) [hibernate-core-4.0.0.Beta1.jar:4.0.0.Beta1] at org.hibernate.engine.transaction.internal.jta.CMTTransaction.join(CMTTransaction.java:149) [hibernate-core-4.0.0.Beta1.jar:4.0.0.Beta1] at org.hibernate.ejb.AbstractEntityManagerImpl.joinTransaction(AbstractEntityManagerImpl.java:1197) [hibernate-entitymanager-4.0.0.Beta1.jar:4.0.0.Beta1] at org.hibernate.ejb.AbstractEntityManagerImpl.postInit(AbstractEntityManagerImpl.java:170) [hibernate-entitymanager-4.0.0.Beta1.jar:4.0.0.Beta1] at org.hibernate.ejb.EntityManagerImpl.(EntityManagerImpl.java:90) [hibernate-entitymanager-4.0.0.Beta1.jar:4.0.0.Beta1] ...

34. Null pointer exception with @StaticMetamodel    forum.hibernate.org

Hello, I am trying to create a type-safe criteria query. this is my function: Code: @Override public List read(String questionnaireId) { CriteriaQuery criteria = getEntityManager().getCriteriaBuilder().createQuery(QuestionnaireClient.class); Root client = criteria.from(QuestionnaireClient.class); ...

35. Null Pointer Exception    forum.hibernate.org

Hello, what is my mistake? I have opened the session with my own connection.(session = _sessions.openSession(con);) The connection is alredy testet. But it throws a null pointer exception... How can i close the session. Should i close my connection first, or after the session? I used this code in a Sevlet witch is inherited from HTTPServlet. Could that be a problem? ...

36. NullPointerException from CollectionPersister.recreate()    forum.hibernate.org

I have no idea why this occurrs, and can't reseach this right now. I have a bi-directional association which is non-cascadable in either direction. Transactions are handled through JTA. Anyone have any ideas? Mappings: Code: ...

37. NullPointerException    forum.hibernate.org

I am trying to load the folowing XML using the code Datastore ds = Hibernate.createDatastore(); ds.storeClass(Department.class); and getting ...

38. NullPointerException in one-to-many    forum.hibernate.org

39. NullpointerException in one-to-many    forum.hibernate.org

That was fast! I think I found the reason. hibernate.cfg.xml Code: jdbc:mysql://localhost:3306/liberty com.mysql.jdbc.Driver root ...

40. strange non repeatable NullPointerException    forum.hibernate.org

Hello, I'm occasionally getting the following NPE exception when I try to load an object. Also, strangely, if I do the same load directly after one that caused an exception the second load will always be successful. Any clues about what could be causing this? I'm using Spring to manage transactions/session. Code: java.lang.NullPointerException at net.sf.hibernate.collection.PersistentCollection.forceInitialization(PersistentCollection.java:331) ...

41. Swarmcache NullPointerException    forum.hibernate.org

42. Beginners Problem: NullPointerException @ getTypeFromXML    forum.hibernate.org

Hi all - I'm a plain old beginner in using hibernate and trying to write some mappings by hand - I've read the reference doc and "Hibernate in Action" - And to my dishonour, i'm still not able to define a simple one-to-many-collection-association between two tables :-| The two mapping files below work without errors until i insert the - ...

43. NullPointerException in Hibernate Set    forum.hibernate.org

Newbie Joined: Wed Oct 15, 2003 10:24 pm Posts: 10 After I call a commit to my transaction, I'm experiencing a problem where a NullPointerException is getting thrown from methods that accesses a lazily loaded Set. The exception is happening when the wrapped java.util.Set in net.sf.hibernate.collection.Set is accessed but appears to still be null. Basically when I call a method like ...

44. NullPointerException while deserializing object graph    forum.hibernate.org

I'm using Hibernate in a (remote) stateless session bean, and I'm getting a NullPointerException as the client tries to deserialize the object graph. The two relevant persistent Objects are a Section, which has a bidirectional one-to-many to SectionBooks. (A SectionBook then has a many-to-one with a Book, but I don't believe the Book is relevant here). The NullPointerException is occurring during ...

45. [slightly OT] How to avoid NullPointerException    forum.hibernate.org

I am developing an application using Hibernate and I find myself doing some goofy things to get around NullPointerExceptions. Let's say that I have a business object Order which is composed as follows: public class Order { private String name; private Address address; private String phone; // default constructor public void Order () { } /* implement basic getters/setters */ } ...

46. NullPointerException in ActionQueue.resumeSuspendedDeletions    forum.hibernate.org

A fairly basic deletion of a persistent object results in a NullPointerException in ActionQueue.resumeSuspendedDeletions. The same code did not produce the exception in Hibernate beta 4. I will look into the source code of Hibernate later on when time permits and add a more detailed description of scenario that led to this error. The error was produced running Junit tests after ...

47. Index error (NullPointerException)    forum.hibernate.org

View unanswered posts | View active topics Board index Hibernate & Java Persistence Hibernate Users All times are UTC - 5 hours [ DST ] Index error (NullPointerException) Page 1 of 1 [ 2 posts ] Previous topic | Next topic Author Message rdeguzman55 Post subject: Index error (NullPointerException) Posted: ...

48. PojoTuplizer.buildProxyFactory NullPointerException    forum.hibernate.org

Author Message teayu Post subject: PojoTuplizer.buildProxyFactory NullPointerException Posted: Fri Apr 22, 2005 7:05 am Newbie Joined: Fri Apr 22, 2005 5:26 am Posts: 1 I encountered an exception when building a session factory for a class involving a UserType, details- Hibernate version: 3.0.1 Mapping documents: Code:

49. NullPointerException while executing posted task    forum.hibernate.org

Hi. There are two issues here: 1) Perhaps you don't like where the messages are going, i.e. to Tomcat console. If this is the issue, upgrade to c3p0-0.9.0-pre5, which will log to log4j or jdk14logging. 2) Perhaps you don't like that Exceptions keep occuring in your application. Though I don't know for sure (and including more config information in your question ...

50. NullPointerException in AbstractQueryImpl Verify parameters    forum.hibernate.org

Newbie Joined: Wed Jan 05, 2005 11:32 pm Posts: 7 I have upgraded my application to Hibernate 3.0.2, mainly to use the getCurrentSession feature. This appears to have had the desired effect: I am albe to insert data in a CMP transaction in WebSphere 5,1 (which this is running in). I have removed all transaction and sesssion management code from my ...

51. NullPointerException in org.hibernate.type.IntegerType.next    forum.hibernate.org

Hi, I'm having trouble adding a serializable array to my object. For the mapping document below, I get a NullPointerException in org.hibernate.type.IntegerType.next. However, if I comment out the , then the object appears to be persisted correctly (although the messages property is not saved). I'm trying to work this down to a test case; does anyone have any ideas? ...

52. [b]Null Pointer Exception when replication is started[/b]    forum.hibernate.org

Im working with Hibernate 2.1, BEA Workshop 8.1.4 and MSSQL Server 2000. I noticed a problem with updating or inserting rows into tables from my application while replication is started. It throws exception in SaveOrUpdate method. But it works fine when inserting rows from Query Analyser. Type of replication - transactional - continous; application, distributor and publisher works on the same ...

53. NullPointerException when running the Hibernate Example    forum.hibernate.org

Hi, I am new to Hibernate. I downloaded the hibernate 3.0.5 and followed the steps to run the example that comes with the hibernate installation. I configured the example to run for Oracle 9i database. When I try to run the example by typing "build eg" I get NullPointerException when it tries to create the Sample test Data. I could see ...

54. NullPointerException in PersistentIndexedElementHolder    forum.hibernate.org

Author Message david.betts Post subject: NullPointerException in PersistentIndexedElementHolder Posted: Thu Jul 14, 2005 1:32 pm Newbie Joined: Fri Jun 17, 2005 11:24 am Posts: 5 I'm getting a NullPointerException when PersistentIndexedElementHolder.readFrom passes a null CollectionPersister.getElementNodeName() return value to org.dom4j.Element.addElement() when trying to get the XML view of the object. This comes from the mapping document not defining a node ...

55. NullPointerException in buildInheritanceSates()    forum.hibernate.org

Beginner Joined: Sun Jun 13, 2004 9:49 pm Posts: 38 Need help with Hibernate? Read this first: http://www.hibernate.org/ForumMailingli ... AskForHelp Hibernate version: 3.1 beta1 Hibernate Annotations version: 3.1 beta4 EJB Presistence: Public Review Full stack trace of any exception that occurs: Code: 2005-08-08 18:08:812 [main] DEBUG com.dolby.pics.core.db.model.impl.BaseDAO [beginTransaction() :43] - com.dolby.pics.core.db.model.impl.BaseDAO trying to start a transaction 2005-08-08 18:08:873 [main] INFO ...

56. NullPointerException returned instead of PersistentSet    forum.hibernate.org

Need help with Hibernate? Read this first: http://www.hibernate.org/ForumMailingli ... AskForHelp Hibernate version: 3.0.5 Name and version of the database you are using: MySQL 4.1 I have a parent-child relationship. Both parent and child are actually the same class (but I think this is irrelevant). The class as (a few) collections. Occasionally (and hence the debuggin problem) if I load a persisted ...

57. java.lang.NullPointerException Error!!!!!    forum.hibernate.org

Newbie Joined: Thu May 12, 2005 12:01 am Posts: 4 Need help with Hibernate? Read this first: http://www.hibernate.org/ForumMailingli ... AskForHelp Hibernate version: hibernate 3.0 Mapping documents:

58. NullPointerException in DefaultFlushEntityEventListener.chec    forum.hibernate.org

Author Message provacanza Post subject: NullPointerException in DefaultFlushEntityEventListener.chec Posted: Mon Sep 12, 2005 4:08 pm Newbie Joined: Mon Sep 12, 2005 3:25 pm Posts: 4 Hello, during my tomcat startup I want to load some data form the DB into the application context. I'm approximately using the code which can be seen farther down. When I run this code, ...

59. java.lang.NullPointerException in AbstractEntityPersister    forum.hibernate.org

Hibernate: insert into JBPM_PROCESSDEFINITION (NAME_, VERSION_, ISTERMINATIONIMPLICIT_, STARTSTATE_) values (?, ?, ?, ?) [22/09/05 19:12:44:106 GMT-03:00] fae902b GraphSession E org.jbpm.db.GraphSession java.lang.NullPointerException [22/09/05 19:12:44:168 GMT-03:00] fae902b SystemOut O 122266 FATAL ctx:[[businessdelegate=WorkflowBusinessDelegate.java, method=publicarProcesso(processVo)] [sessionFacade=WorkflowSessionFacadeBean.java, method=publicarProcesso(processVo)] [classe=MainWorkflow.java, method=deployProcessDefinition(zipInputStream)]] - couldn't save process definition 'ProcessDefinition(teste)' java.lang.RuntimeException: couldn't save process definition 'ProcessDefinition(teste)' at org.jbpm.db.GraphSession.saveProcessDefinition(GraphSession.java:35) ...

60. NullPointerException in 'before_completion synchronization'    forum.hibernate.org

Author Message rm2558 Post subject: NullPointerException in 'before_completion synchronization' Posted: Mon Oct 03, 2005 2:27 am Newbie Joined: Mon Oct 03, 2005 1:25 am Posts: 2 Location: Brisbane I am using Hibernate on Websphere 5.1.3 with Container Managed JTA Transcations in facade Session Beans. hibernate.transaction.factory_class=org.hibernate.transaction.CMTTransactionFactory hibernate.transaction.manager_lookup_class=org.hibernate.transaction.WebSphereTransactionManagerLookup The facade Session Beans are invoked remotely from Cactus Tests in a seperate ...

61. Absurd null pointer exception    forum.hibernate.org

I am having what appears to be an absurd problem with Tomcat and null pointers (and Hibernate, although this seems only marginally related to Hibernate). When I creat an object via a form, passed to a servlet, then back to the JSP to render the view, I consistently get a null pointer exception. The object is being persisted with no issues, ...

62. annoying NullPointerException    forum.hibernate.org

63. java.lang.NullPointerException one-to-many exception pls hel    forum.hibernate.org

I have the following exception when I try to get a Set from one-to-many relation. I have other collection that works well but this set throws this kind of exception when I try to retrieve. Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at org.hibernate.tuple.AbstractTuplizer.createProxy(AbstractTuplizer.java:249) at org.hibernate.persister.entity.BasicEntityPersister.createProxy(BasicEntityPersister.java:2813) at org.hibernate.event.def.DefaultLoadEventListener.createProxyIfNecessary(DefaultLoadEventListener.java:260) at org.hibernate.event.def.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:205) at org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:121) at org.hibernate.impl.SessionImpl.internalLoad(SessionImpl.java:602) at org.hibernate.type.EntityType.resolveIdentifier(EntityType.java:255) at org.hibernate.type.EntityType.resolve(EntityType.java:280) at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:105) at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:506) at ...

64. NullPointerException in AbstractBatcher    forum.hibernate.org

Newbie Joined: Thu Oct 13, 2005 8:51 pm Posts: 9 I'm seeing the below using WAS 6 and SqlServer 2000, with IBM's embedded SqlServer driver used for a container managed DataSource. I looked at the source and here's where it's blowing up: private void closePreparedStatement(PreparedStatement ps) throws SQLException { try { log.trace("closing statement"); ps.close(); <--- This is causing the NullPointer What's ...

65. Null Pointer Exception with every alternate request.    forum.hibernate.org

Hi, I have configured oracle datasource in WSAD5.1, i am trying to write to database using hibernate framework from a web application. i have copied all the required jar files into WEB-INF/lib folder, and created hibernate.cfg.xml, Person.hbm.xml ,and a TestServlet.java, following is the code listing for each file hibernate.cfg.xml: ...

66. many-to-one problem - NullPointerException only while loadin    forum.hibernate.org

I'm having problems with a many-to-one mapping between two entities: CuttingSheet and Site. I can insert/delete/update the entities without any problems but when I try to load it I'm getting a NullPointerException from somewhere within Hibernate. Some background: - Hibernate 3.1.3 - launching from within Eclipse 3.1.2 but everyting is in one project and all the hibernate libraries are in the ...

67. CastFunction throws NullPointerException    forum.hibernate.org

public String render(List args, SessionFactoryImplementor factory) throws QueryException { if ( args.size()!=2 ) { throw new QueryException("cast() requires two arguments"); } String type = (String) args.get(1); ...

68. Getting java.lang.NullPointerException    forum.hibernate.org

Am using Hibernate 3.1.3 with Spring 1.2.8 Have been getting java.lang.NullPointerException when I make a call to getHibernateTemplate().load(User.class,username) . So in order to make sure that I'm getting HibernateTemplate I changed my method call to HibernateTemplate ht = getHibernateTemplate() ; User user = ht.load(User.class,username)....put a watch on ht to check if it null, but its not. I'm running out of ideas ...

69. NullPointerException in QueryPlanCache.getHQLQueryPlan    forum.hibernate.org

Hai, We are getting the follwoing NullPointerException(see below for detail) from Hibernate Code in our performance tests when we execute the following hql query : select et.operateurTechnique from EtatGmta eg, EtatTechnique et, DroitAcquis da, ProduitTechniqueProfMediaguard ptpmg, ProduitTechniqueProfMerlin ptpm where eg.gmta = ? and eg.situation = ? and et.etatGmta = eg and da.etatTechnique = et and (da.produitTechnique = ptpmg or da.produitTechnique = ...

70. Null pointer Exception    forum.hibernate.org

71. NullPointerException    forum.hibernate.org

When I run the following code: Session session = HibernateUtil.getSession(); ReceiptVoucher receiptVoucher = new ReceiptVoucher(); Criteria criteria = session.createCriteria(receiptVoucher.getClass()); criteria.list(); HibernateUtil.closeSession(); ............... I get the following exception: Exception in thread "main" java.lang.NullPointerException at org.hibernate.tuple.AbstractEntityTuplizer.createProxy(AbstractEntityTuplizer.java:372) at org.hibernate.persister.entity.AbstractEntityPersister.createProxy(AbstractEntityPersister.java:3232) at org.hibernate.event.def.DefaultLoadEventListener.createProxyIfNecessary(DefaultLoadEventListener.java:237) at org.hibernate.event.def.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:174) at org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:86) at org.hibernate.impl.SessionImpl.fireLoad(SessionImpl.java:871) at org.hibernate.impl.SessionImpl.internalLoad(SessionImpl.java:839) at org.hibernate.type.EntityType.resolveIdentifier(EntityType.java:266) at org.hibernate.type.EntityType.resolve(EntityType.java:303) at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:116) at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:842) at org.hibernate.loader.Loader.doQuery(Loader.java:717) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2145) at ...

72. NullPointerException at AbstractEntityTuplizer.java:372    forum.hibernate.org

Hello, Can I somehow turn the debug on to find out what exactly does this error refer to? I'm running Hibernate 3.1rc2 in Sun app server (8.2) under jdk 1.5. This error is so vague that it's hard to determine the problem. Any ideas on the cause of the error or on how to make it more verbose would be greatly ...

73. NullPointerException in Hiberante code.    forum.hibernate.org

74. NullPointerException @ org.hibernate.type.IntegerType.next()    forum.hibernate.org

Newbie Joined: Fri Dec 15, 2006 7:07 pm Posts: 7 Location: Luxembourg Dear all With Hiberate 3.1 I am getting a java.lang.NullPointerException at org.hibernate.type.IntegerType.next(IntegerType.java:59) when executing save() and flush() on an object which has just been created. All docs and comments talk about a wrong unsaved-value mapping. But what does that mean? I cannot really see anything. At the moment I ...

75. Null Pointer Exception at AbstractBatcher.closePreparedState    forum.hibernate.org

I am getting this expcetion, when trying to insert a simple statement into SQL Server2000 with hibrante-mapping for ID generator class as [b]identity or native[/b] from a [b]Websphere container [/b]either with a Webspehere embedded JDBC driver or JTDC driver for SQLServer. From outside the container it works fine either with Microsoft or JTDC drivers. But with Webspehere embedded JDBC driver it ...

76. Null Pointer Exception    forum.hibernate.org

Hello all, I am trying to run a very basic application which inserts one record into a table created in a SQL Server database. Here is my hibernate.cfg.xml file: com.microsoft.jdbc.sqlserver.SQLServerDriver jdbc:microsoft:sqlserver://my_server_name/my_database_name testuser testpass 10 true org.hibernate.dialect.SQLServerDialect update Here is my Java class: public static void ...

77. java.lang.NullPointerException throwed when doingPersistence    forum.hibernate.org

Author Message rfan Post subject: java.lang.NullPointerException throwed when doingPersistence Posted: Mon Jun 18, 2007 4:12 pm Newbie Joined: Mon Jun 18, 2007 3:43 pm Posts: 3 Im using Hibernate3. I am trying to add a record of "orderdetail", also setting its many-2-one association "order", which include a many-2-one association with "employer". Mycode is: Code: public class OrderdetailDaoTest { ...

78. Java Null Pointer Exception    forum.hibernate.org

Hi all I am getting exception in the following program when i try to execute. Code: package roseindia.tutorial.hibernate; import org.hibernate.Session; import org.hibernate.SessionFactory; import org.hibernate.cfg.Configuration; public class FirstExample { public static void main(String[] args) { Session session = null; try{ // This step will read hibernate.cfg.xml and prepare hibernate for use SessionFactory sessionFactory = new Configuration().configure().buildSessionFactory(); session =sessionFactory.openSession(); //Create new instance of ...

79. java.lang.NullPointerException    forum.hibernate.org

I have a Struts and Hibernate based application. After uploading application on the server, when I login I get "HTTP Status 500 - Internal Server Error". The Exception is "javax.servlet.ServletException" and the root cause of the exception is: "java.lang.NullPointerException" at line: tx = session.beginTransaction(); Here are few lines of code: Code: Transaction tx = null; ...

80. NullPointerException in IdentityMap    forum.hibernate.org

81. Error java.lang.NullPointerException hibernate    forum.hibernate.org

Newbie Joined: Thu Mar 06, 2008 5:08 am Posts: 3 hello everybody; I'm developping a web application using Struts 1.1 , Hibernate 3.1 and Mysql , and I've got this message error: Quote: Etat HTTP 500 - -------------------------------------------------------------------------------- type Rapport d'exception message description Le serveur a rencontr une erreur interne () qui l'a empch de satisfaire la requte. exception javax.servlet.ServletException org.apache.struts.action.RequestProcessor.processException(RequestProcessor.java:545) ...

82. Null pointer exception    forum.hibernate.org

I am new to hibernate, the below code is downloaded from roseindia.com. When i try to run this program in eclipse , I got a Null pointer exception. My question is where to put my hibernate.cfg.xml file ? though I placed it in my bin folder. Still program is not reading .Please help me out. JAva code : public class FirstExample ...

83. NullPointerException on HqlSqlWalker.createFromJoinElement    forum.hibernate.org

I am getting a NPE on executing query using joins - Mapping:- ------------------------------------------------------------------------------------ ...

84. NullPointerException    forum.hibernate.org

...

85. RegionFactoryCacheProviderBridge: NullPointerException?    forum.hibernate.org

I'm trying to get caching working in Hibernate Core, but I'm getting a NullPointerException when I access a cached object the second time (i.e. when Hibernate actually resorts to a cache). Here is the full stack trace: Code: SEVERE: Servlet.service() for servlet default threw exception java.lang.NullPointerException at org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge.nextTimestamp(RegionFactoryCacheProviderBridge.java:85) at org.hibernate.impl.SessionFactoryImpl.openSession(SessionFactoryImpl.java:526) at org.hibernate.impl.SessionFactoryImpl.openSession(SessionFactoryImpl.java:535) ...

86. NullPointerException in getHibernateLazyInitializer:javassis    forum.hibernate.org

I'm not sure if this is a bug in Hibernate or a bug in javassist . I'm trying to isolate under exactly which circumstances this happens. Most of the time everything is OK but in 3 specific integration test classes I'm seeing the exception shown below. It doesn't appear to be a race condition as it happens every time I run ...

87. NullPointerException in Hibernate    forum.hibernate.org

Hello! I'd like to report a NullPointerException internal to hibernate. The method org.hibernate.event.def.DefaultDeleteEventListener.deleteTransientEntity(...) is called with a "null" as parameter for the "transientSet". This was passed down many levels from org.hibernate.engine.Cascade.deleteOrphans(...), where the "null" is hard wired into the sources. I hope you can fix this please. Regards Holger Hibernate version: 3.2.6 Full stack trace of any exception that occurs: Code: ...

88. getting NullPointerException in creatProxy() method.    forum.hibernate.org

When i am trying to call list() method in the hibernate java.lang.NullPointerException at org.hibernate.tuple.AbstractEntityTuplizer.createProxy(AbstractEntityTuplizer.java:372) at org.hibernate.persister.entity.AbstractEntityPersister.createProxy(AbstractEntityPersister.java:3121) at org.hibernate.event.def.DefaultLoadEventListener.createProxyIfNecessary(DefaultLoadEventListener.java:232) at org.hibernate.event.def.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:173) at org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:87) at org.hibernate.impl.SessionImpl.fireLoad(SessionImpl.java:889) at org.hibernate.impl.SessionImpl.internalLoad(SessionImpl.java:857) at org.hibernate.type.EntityType.resolveIdentifier(EntityType.java:266) at org.hibernate.type.EntityType.resolve(EntityType.java:303) at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:113) at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:842) at org.hibernate.loader.Loader.doQuery(Loader.java:717) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2150) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2029) at org.hibernate.loader.Loader.list(Loader.java:2024) at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:369) at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:300) at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:153) at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1127) at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79) at com.jiva.pojo.AbstractDAO.findAll(AbstractDAO.java:234) at com.jiva.pojo.StateDAO.findAll(StateDAO.java:95) at com.jiva.web.CampaignFormController.formBackingObject(CampaignFormController.java:106) at ...

89. NullPointerException in Configuration.doConfigure    forum.hibernate.org

java.lang.NullPointerException at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1214) at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1184) at org.hibernate.cfg.Configuration.configure(Configuration.java:1127) at org.springframework.orm.hibernate3.LocalSessionFactoryBean.afterPropertiesSet(LocalSessionFactoryBean.java:604) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1058) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:363) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:226) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:269) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:318) at org.springframework.context.support.FileSystemXmlApplicationContext.(FileSystemXmlApplicationContext.java:83) at org.springframework.context.support.FileSystemXmlApplicationContext.(FileSystemXmlApplicationContext.java:68) ...

90. Hiberate NullPointerException when using JPA+EntityMode.DOM4    forum.hibernate.org

java.lang.NullPointerException at org.hibernate.type.EntityType.getIdentifierType(EntityType.java:520) at org.hibernate.type.EntityType.setToXMLNode(EntityType.java:377) at org.hibernate.property.Dom4jAccessor$ElementSetter.set(Dom4jAccessor.java:333) at org.hibernate.tuple.component.AbstractComponentTuplizer.setPropertyValues(AbstractComponentTuplizer.java:104) at org.hibernate.type.ComponentType.setPropertyValues(ComponentType.java:381) at org.hibernate.type.ComponentType.resolve(ComponentType.java:609) at org.hibernate.type.ComponentType.nullSafeGet(ComponentType.java:298) at org.hibernate.persister.collection.AbstractCollectionPersister.readElement(AbstractCollectionPersister.java:725) at org.hibernate.collection.PersistentElementHolder.readFrom(PersistentElementHolder.java:125) at org.hibernate.loader.Loader.readCollectionElement(Loader.java:1031) ...

91. NullPointerException in EntityAction.getId()    forum.hibernate.org

Newbie Joined: Sat Aug 08, 2009 12:00 pm Posts: 1 Hello, I'm getting an NPE in EntityAction.getID() in a very specific case. Basically i have 4 types of Entities (i renamed them to clarify their Relations): TOP: TOP owns a List of UPPERMIDDLE Entities (OneToMany) UPPERMIDDLE: UPPERMIDDLE holds one TOP-Entity (ManyToOne) and owns a List of LOWERMIDDLE-Entities (OneToMany) LOWERMIDDLE: LOWERMIDDLE holds ...

92. java.lang.NullPointerException in Hibernate    forum.hibernate.org

Hi! I have a problem in getting the list of records in Hibernate. It returns a NullPointerException during runtime everytime when I test my query. Here are the following codes that I used: codes from HcfAutDAO.java Code: final public static String HQL_DATA = "select hcf.auauno, hcf.auapfl, hcf.auapyr, hcf.auapmo, hcf.auapda, hcf.auvfyr, hcf.auvfmo, hcf.auvfda, hcf.auvtyr, hcf.auvtmo, hcf.auvtda ...