If you create a class to implement JDBCSqlHandler, you can get log4j message
by 
LoggingEvent.getMessage()

So you can divide the message column as you like. And insert the divided
messages into database separated.

There are examples from that link.

Is it enough?
-----Original Message-----
From: Magnus Andersson [mailto:[EMAIL PROTECTED] 
Sent: 2004å1æ14æ 17:58
To: Log4J Users List
Subject: Re: RE: RE: how to divide message column?

Âyes i have checked there. But i can't find where you configure it. I find
DYNAMIC columns.
I should look further. Thanks!

------ Ursprungligt meddelande -------------------Â
FrÃn:  Yu Xiang Xi  (Maveo)  <[EMAIL PROTECTED]>Â
Datum: Wed, 14 Jan 2004 09:38:31 +0800Â
Ãmne: RE: RE: how to divide message column?Â

Hope this link helps u.
http://www.mannhaupt.com/danko/projects/index.html

BR.
Xi Yuxiang
Jan.14th, 2003
-----Original Message-----
From: Magnus Andersson [mailto:[EMAIL PROTECTED] 
Sent: 2004?1?13? 18:14
To: Log4J Users List
Subject: Re: RE: how to divide message column?

ÂDo you mean SqlHandler in JDBCAppender to log4j or just a Sqlhander?
give me an example?

------ Ursprungligt meddelande -------------------Â
FrÃn:  Yu Xiang Xi  (Maveo)  Â
Datum: Tue, 13 Jan 2004 15:33:52 +0800Â
Ãmne: RE: how to divide message column?Â

Implement a SqlHandler instead of using sql in log4j.properties can help
resolve this issue. 

-----Original Message-----
From: Magnus Andersson [mailto:[EMAIL PROTECTED] 
Sent: 2004?1?13? 15:27
To: [EMAIL PROTECTED]
Subject: how to divide message column?

I got a problem. 
Irecived a message that looks like this: 
2004-jan-07 14:16:03,125 INFO     MyApp MyApp main - d9d73; 9df834jdf9;
9cvkdc9; 9didem89;

And the problem is. That i want to put everything into a jdbc database
and the message should be divided 
so, that after every ";" semicolon i want it to put into a new
column i the database like these


log4j.appender.ROOT.sql=insert into JDBCTEST (Date, Priority, Logger, 
Method, 
Message1 ,Message2,Message3,Message4)

Is that possible. Or should i divide it in the java code?

_______________________________________________________________
  Vinn en helg pà spa fÃr 2 personer ? http://resor.spray.se



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

_______________________________________________________________
  Vinn en helg pà spa fÃr 2 personer ? http://resor.spray.se



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

___________________________________________________________________
AvslÃjad! Rolig feature - se anonymt vad folk sÃker pà Lycos SÃk:
http://lycos.spray.se/fluktaren.html



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to