org.apache.catalina.valves.JDBCAccessLogValve
It is more a documentation problem than a bug
For the table access the column name "user" is used. This is a reserved word in
SQL92, and causes problems with Postgres 8.0.3

You can change it at your JDBCValve
<Valve className="JDBCAccessLogValve"
driverName="your_jdbc_driver"
connectionURL="your_jdbc_url"
pattern="combined" resolveHosts="false"
userField="userName"
/>
But I also think user is not a nice default, and we better change it.
Thanks reporting it.

How do we get this Valve working for Oracle.
1. Oracle doesn't have Auto_Increment, instead they have sequences.
2. Oracle cannot directly create a table as access. It had to be "access".
(Anyways I worked it around with tableName = "accesslogs" in the server.xml)
I had to strip down the table struct to this
CREATE TABLE accesslogs (
id VARCHAR(255),
remoteHost CHAR(15),
userName CHAR(15),
timestamp TIMESTAMP,
virtualHost VARCHAR(64),
method VARCHAR(8),
query VARCHAR(255),
status SMALLINT,
bytes INT,
referer VARCHAR(128),
userAgent VARCHAR(128)
);
Can this valve provide fix for the default table struct?
Also, the valve fails to log in the Oracle DB if I use the following pattern
pattern="Combined Log Format: %{X-Forwarded-For}i %a %h %q %v %D %T %l %u %t %r %s %b %{User-Agent}i %{Referer}i"
It works well for pattern="combined"

Bugzilla is not a support forum. Please direct your questions to the Tomcat users mailing list rather than re-opening a five year old resolved bug.

This is ASF Bugzilla: the Apache Software Foundation bug system. In case
of problems with the functioning of ASF Bugzilla, please contact
bugzilla-admin@apache.org.
Please Note: this e-mail address is only for reporting problems
with ASF Bugzilla. Mail about any other subject will be silently
ignored.