[opencms-dev] Re: SAPDB reports Missing delimiter in updateAllResourceFlags() - SOLUTION
Scott Newham
scott at wranglers.com.au
Sat Mar 13 04:17:02 CET 2004
Hi Folks,
I've answered my own question here, but thought other may have the same
issue:
The issue is that SAPDB does not allow table names in the target of an SQL
UPDATE query.
Therefore queries such as:
UPDATE CMS_RESOURCES SET CMS_RESOURCES.RESOURCE_FLAGS = ?
would raise the Missing Delimiter exception (not really a very helpful error
message from the sapdbc folks).
The solution was to go through the file
com/opencms/file/genericSql/query.properties and look for instances where
the table name is given as the target of an update and remove the table
name. I have found only four instances (so far).
Regards,
Scott
*Newbies only:
Oh, and for folks with limited exposure to building opencms from source, can
I suggest merely going to the WEB-INF/lib file and unziping the single file
query.properties, updating it and then refreshing the opencms.jar file.
(On my FreeBSD box the sequence is:
unzip opencms.jar com/opencms/file/genericSql/query.properties
Then use a text editor to make the changes to the file such as:
UPDATE CMS_RESOURCES SET CMS_RESOURCES.RESOURCE_FLAGS = ?
becomes
UPDATE CMS_RESOURCES SET RESOURCE_FLAGS = ?
Then save the file and (assuming you are still in the directory with
opencms.jar in it):
zip -r opencms.jar com/opencms/file/genericSql/query.properties
You will then need to restart your servlet runner (tomcat or jboss or
whatever))
----- Original Message -----
From: Scott Newham
Sent: Saturday, March 13, 2004 1:59 PM
Subject: SAPDB reports Missing delimiter in updateAllResourceFlags()
Hi Folks,
On installation, I get a missing delimiter error. There was a msg posted a
long time ago about this, but no solution.
My problem is that I have three installations of OpenCMS, all running
against SAPDB. Two work beautifully, and one fails to complete its
installation with the error (upsidedown as it appears in the status window):
1130: at
com.opencms.file.genericSql.CmsDbAccess.updateAllResourceFlags(CmsDbAccess.j
ava:12727)
1129: root cause was com.sap.dbtech.jdbc.exceptions.DatabaseException:
[-5016] (at 39): Missing delimiter: =
1128: com.opencms.core.CmsException: 4 Sql exception. Detailed error:
[com.opencms.file.genericSql.CmsDbAccess.updateAllResourceFlags()] [-5016]
(at 39): Missing delimiter: =.
1127: !!! Exception com.opencms.core.CmsException:
[com.opencms.file.genericSql.CmsDbAccess.updateAllResourceFlags()] [-5016]
(at 39): Missing delimiter: =
1126: ------ Checking filesystem links ...
At this point I can browse the newly created tables and there is data there.
CMS_RESOURCES is, as far as I can see, correct.
The version that does not complete the installation is:
Server 1:
RH Linux ES
Tomcat 4.1.20
Sun JDK 1.4.2
JDBC connection string:
jdbc:sapdb://dbdw1/dwdb?sqlmode=ORACLE&trace=jdbc_trace.log
OpenCMS 5.0.1
(I've also tried this with openCMS5.0 with the same error).
Server 2
RH Linux ES
SAPDB 7.4 (from RPMs)
The difference between this and the other two installations are:
1. They run on other OSes (one Win2000 the other Debian)
2. On the other two installations, the SAPDB and TOMCAT are on the same
machine.
Any suggestions would be most gleefully received. I'm under a very tight
deadline to go to production.
Thanks in advance,
Scott
More information about the opencms-dev
mailing list