Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm having a problem with quartz, it gives a java.sql.SQLException with this error message:

ERROR [PortalJobStore:3799] ClusterManager: Error managing cluster: Failure obtaining db row lock: Line 1: FOR UPDATE clause allowed only for DECLARE CURSOR.

Apparently quartz in Liferay Enterprise Edition tries to use an SQL that isn't allowed by MSSQL.

What can be done to fix this?

share|improve this question
up vote 2 down vote accepted

You can tell quartz what SQL to use by adding this property org.quartz.jobStore.selectWithLockSQL in the file like this:

org.quartz.jobStore.selectWithLockSQL = SELECT * FROM {0}LOCKS UPDLOCK WHERE LOCK_NAME = ?
share|improve this answer
I actually joined serverfault only to upvote both your question and answer. Thanks a lot! – yair Mar 7 '13 at 19:53

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.