inputUnitsProcessed Property

Log Parser

inputUnitsProcessed Property

Returns the total number of input records processed so far by a query executed with the Execute method.

Read-only property.


Script Syntax

value = objLogRecordSet.inputUnitsProcessed;


Return Value

An integer value containing the total number of input records processed so far by the query that returned the LogRecordSet object.


Examples

JScript example:

var oLogQuery = new ActiveXObject("MSUtil.LogQuery");

// Create query text
var strQuery = "SELECT * FROM System";

// Execute query and receive a LogRecordSet
var oRecordSet = oLogQuery.Execute( strQuery );

// Visit all records
while( !oRecordSet.atEnd() )
{
        // Display number of input records processed so far
        WScript.Echo( "Input Records Processed: " + oRecordSet.inputUnitsProcessed );

	// Get a record
	var oRecord = oRecordSet.getRecord();

	// Advance LogRecordSet to next record
	oRecordSet.moveNext();
}

// Display total number of input records processed
WScript.Echo( "Total Input Records Processed: " + oRecordSet.inputUnitsProcessed );

// Close LogRecordSet
oRecordSet.close();

VBScript example:

Dim oLogQuery
Dim oRecordSet
Dim strQuery

Set oLogQuery = CreateObject("MSUtil.LogQuery")

' Create query text
strQuery = "SELECT * FROM System"

' Execute query and receive a LogRecordSet
Set oRecordSet = oLogQuery.Execute( strQuery )

' Visit all records
DO WHILE NOT oRecordSet.atEnd

        ' Display number of input records processed so far
        WScript.Echo "Input Records Processed: " & oRecordSet.inputUnitsProcessed

	' Get a record
	Set oRecord = oRecordSet.getRecord

	' Advance LogRecordSet to next record
	oRecordSet.moveNext

LOOP

' Display total number of input records processed
WScript.Echo "Total Input Records Processed: " & oRecordSet.inputUnitsProcessed

' Close RecordSet
oRecordSet.close


See also:

LogRecordSet Object
Log Parser COM API Overview
C# Example


© 2004 Microsoft Corporation. All rights reserved.