« Previous Next »

Thread: Tough one: CANNOT figure out how to get the last field to format properly

Last post 08-05-2009 12:04 PM by maximusdm. 1 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (2 items)

Sort Posts:

  • 08-05-2009, 11:01 AM

    Tough one: CANNOT figure out how to get the last field to format properly

    Hi all.  please help! 

    Everything works perfect except for the last field "ExceptionDetails" which contains various lines in the log. This is my command line:

    logparser -i:TSV -iSeparator:"|" -headerRow:OFF -iHeaderFile:"c:\Header.tsv" -nSkipLines:2 -iTsFormat:"yyyy-MM-dd?hh:mm:ss" -o:CSV "select UTCtime,VHOtime,EventID,EventType,ComponentDoingTheLogging,
    ComponentCausingTheLogging,ProcessID,ThreadID,Message,ExceptionDetails INTO C:\a.csv FROM C:\Trace.log"

    This is a sample of 1 line of my log:

    2009:07:30 15:00:23:41|2009:07:30 11:00:23:41T-4|13609|Warning|Microsoft.Iptv.Server.Notification.DeliveryService.NDS.Unexpected exception when registering NDS|NotificationDeliveryService.exe||2688|6|The system encountered an unexpected exception when attempting to start the NDS|
    Exception Details:
    Type: SoapException
    Message: Server was unable to process request. ---> The ConnectionString property has not been initialized.
    Source: System.Web.Services
    StackTrace: at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall) at System.Web.Services.Protocols.SoapHttpClientProtocol.EndInvoke(IAsyncResult asyncResult)
    at Microsoft.Iptv.Proxy.Notification.Controller.NotificationController.EndSetDeliveryService(IAsyncResult asyncResult)
    at Microsoft.Iptv.Server.Notification.DeliveryService.NDS.FirstBootThread()^

    So the goal is to fit everything (after "Exception Details:") in one cell. When I open the file in excel everything is messed up. If I output to a datagrid everything is messed up to.

    Thank you for your help.

     

    MDM
  • 08-05-2009, 12:04 PM In reply to

    Re: Tough one: CANNOT figure out how to get the last field to format properly

    the only solution I found was to replace all the \r\n with a empty space. So I am doing my own parsing before I handle the file to LogParser.

    I was actually trying to find a way to have LogParser do all the job since I am sure is way faster than having me to open the log and parse it myself.

    Thanks.

     

    MDM
Page 1 of 1 (2 items)
Microsoft Communities