Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / May 2007

Tip: Looking for answers? Try searching our database.

log4j | logging class member variables into oracle db | JDBCAppender.

Thread view: 
siva - 17 May 2007 03:48 GMT
Hi.

I m fairly new to log4j and trying things out as part of a new
project. I m using JDBCAppender to log statements, and I have a
scenario where I want to post class member variables to the oracle
table.
for example.
I have oracle table defined as - ORA_SIGN_LOG
USER_NAME
PASSWORD
DATE_TIME_STAMP
MESSAGE

I want to supply values for the first 3fields from my java class (NOT
as part of the message as an object/) and able to log it to
corresponding fields in the table. I thought of putting as part of the
message and slicing it into pieces using sql in the log4j properties,
curious to know whether any inbuilt methodology from log4j. googled
with not much help.

Thanks in advance.
Sivaram
Lew - 17 May 2007 13:08 GMT
> Hi.
>
[quoted text clipped - 15 lines]
> curious to know whether any inbuilt methodology from log4j. googled
> with not much help.

Be careful about doing too much in logging - you could wind up with exceptions
spewing from the logging action, that would then need to be logged, spewing
more exceptions, ...

Also, logging levels change in production - a sysadmin might raise or lower
the logging level as needed to diagnose situations.  Be sure to account for that.

Signature

Lew



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.