log4j中将日志插入到数据库中遇到的问题^_^

03-12-31 togetherj
log4j.appender.A3 = org.apache.log4j.jdbc.JDBCAppender

log4j.appender.A3.BufferSize = 40

log4j.appender.A3.Driver = sun.jdbc.odbc.JdbcOdbcDriver

log4j.appender.A3.URL = jdbc:odbc:emmis

log4j.appender.A3.User = sa

log4j.appender.A3.Password = 815023

log4j.appender.A3.layout = org.apache.log4j.PatternLayout

log4j.appender.A3.layout.ConversionPattern = insert into log4j(thread, priority, category, message) values ('%t', '%-5p', '%c', '%m')我像这样写配置文件怎么不能向数据库中插入数据呀!

猜你喜欢