Answer the question
In order to leave comments, you need to log in
How to parse log file in C# and write data to database?
Good afternoon.
Please tell me how to correctly parse the log file with the following structure:
Jun 5 04:49:08 192.168.1.1 : %SNMP-3-INPUT_QFULL_ERR: Packet dropped due to input
That is, you need to split it into 5 columns, since the data there is different.
Thanks in advance !
Answer the question
In order to leave comments, you need to log in
And if there is a gap, then somehow you have to pervert.
how different can they be? If the structure is always the same, I would do something similar with a java stringtokenizer. https://stackoverflow.com/questions/70405/does-cs...
or prescribe an appropriate rexex
How to parse log file in C# and write data to database?Usually this is already done for you - the DBMS delivery includes data import/export utilities.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question