Posts Tagged Fix

NonUniqueResultException in Hibernate

March 6, 2012
NonUniqueResultException in Hibernate

Sometimes we will get the NonUniqueResultException when we tried to get the result-set by executing query using Hibernate. The following is the stack trace of the exception: query did not return a unique result: 2 org.hibernate.NonUniqueResultException: query did not return a unique result: 2 at org.hibernate.internal.AbstractQueryImpl.uniqueElement( at org.hibernate.internal.AbstractQueryImpl.uniqueResult( at org.bss.dao.SampleDAO.main( This happens because you’re expecting [...]

Fixing ‘Could not reserve enough space for object heap’ With Ant tool

December 6, 2011
Fixing 'Could not reserve enough space for object heap' With Ant tool

Error occurred during initialization of VM Could not reserve enough space for object heap Could not create the Java virtual machine. This happens only because there is no enough space for ANT build tool to run the scripts. So first fix the heap space. On UNIX: set ANT_OPTS = -Xms16m -Xmx512m On WINDOWS: Add environment [...]

Fixing Invalid command ‘RewriteEngine’

October 21, 2011
Fixing Invalid command 'RewriteEngine'

[Mon Oct 10 21:57:06 2011] [alert] [client] C:/wamp/www/web-app/.htaccess: Invalid command ‘RewriteEngine’, perhaps misspelled or defined by a module not included in the server configuration This happens only when rewrite module on your Apache server is off. Do the following steps in order to resolve the problem: Go to this folder C:\wamp\bin\apache\Apache2.2.17\conf or corresponding ‘conf‘ [...]


If you have a Tip, Comment, Article or anything you want to share, please send it to: