Help Mode
"Help Mode", activated with the "-h" switch, offers users
the possibility to access "quick reference" help topics displayed to the
console output.
The help topics, selectable through additional command-line arguments, are:
- General Usage
- Query Language Syntax
- Functions Syntax
- Input and Output Formats
- Conversion Mode
- Query Examples
General Usage Help
The Log Parser command-line executable usage help is accessed with the following command:
C:\>LogParser -h
Query Language Syntax Help
The Log Parser SQL-Like language syntax help is accessed with the following command:
C:\>LogParser -h GRAMMAR
Functions Syntax Help
The Log Parser SQL-Like language functions syntax help is accessed with commands having the following syntax:
LogParser |
|
C:\>LogParser -h FUNCTIONSTyping a function name following the help command displays the syntax of the selected function only:
C:\>LogParser -h FUNCTIONS SUBSTRTyping the first few letters of a function name displays the syntax of all the functions whose name starts with the specified letters:
C:\>LogParser -h FUNCTIONS STR
Input and Output Formats Help
Input and output formats help is displayed with commands having the following syntax:
LogParser |
|
LogParser |
|
C:\>LogParser -h -i:IISW3CThe output of this command gives a detailed overview of the IISW3C input format, including the syntax of the <from_entity>, a list of all the supported properties together with their default values, the structure of the records produced by the input format (field names and types), and examples of queries using the input format.
When an input format retrieves field information from the data that needs to be parsed, the help command can include the from-entity from which the field information is to be gathered.
For example, the CSV input format examines the input files to retrieve the names and types of the input record fields that will be exported. A help command aimed at displaying the input record fields exported by the CSV input format when parsing a specific file should include the filename from-entity, as shown in the following example:
C:\>LogParser -h -i:CSV TestLogFile.csvIn addition, since the parameters of some input formats can affect the structure of the input records, help commands can include these parameters to display the varying input record structures.
For example, the NETMON input format has a "fMode" parameter that can be used to specify how the input records should be structured. A help command aimed at displaying the input record fields exported by the NETMON input format when the "fMode" parameter is set to "TCPConn" should include this parameter, as shown in the following example:
C:\>LogParser -h -i:NETMON -fMode:TCPConn
Conversion Mode Help
Conversion mode help is accessed with commands having the following syntax:
LogParser |
|
C:\>LogParser -h -cThe following command displays help on the conversion between the specified log file formats, including the full text of the built-in query that performs the conversion:
C:\>LogParser -h -c -i:BIN -o:W3C
Query Examples Help
Examples of queries and commands can be displayed with the following command:
C:\>LogParser -h EXAMPLES