Microsoft KB Archive/903649

= FIX: TI appends null characters to the data stream that is sent to the host when you use the TI User Data programming model in Host Integration Server 2004 =

Article ID: 903649

Article Last Modified on 12/4/2007

-

APPLIES TO


 * Microsoft Host Integration Server 2004 Standard Edition

-





SYMPTOMS
In Microsoft Host Integration Server 2004, Transaction Integrator (TI) Windows Initiated Processing (WIP) methods may contain parameters to be sent to the host that are defined as variable length arrays. These parameters may be defined by using the OCCURS DEPENDING ON property entry in the TI Designer.

When you use the TI User Data programming model, TI appends null characters to the data stream if the following conditions are true:
 * The value of the length specifier for the array is zero at runtime.
 * The array parameter is defined in a Structure or in a User-Defined Type.
 * The data type for the array is a Data Table or a Recordset.

The number of null characters that TI appends to the data stream equals the maximum number of bytes for the array definition.



CAUSE
The value for the overall length of the data stream is not adjusted when the following conditions are true:
 * The specified length of the variable-length array is set to zero.
 * The data definition includes Data Tables or Recordsets, and the Data Tables or Recordsets appear within Structures or User-Defined Types.



Hotfix information
A supported hotfix is now available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem. This hotfix might receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next service pack that contains this hotfix.

To resolve this problem, submit a request to Microsoft Online Customer Services to obtain the hotfix. To submit an online request to obtain the hotfix, visit the following Microsoft Web site:

http://go.microsoft.com/?linkid=6294451

Note If additional issues occur or any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. To create a separate service request, visit the following Microsoft Web site:

http://support.microsoft.com/contactus/?ws=support

File information
The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.

Note Because of file dependencies, the most recent hotfix that contains these files may contain additional files.



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section.



MORE INFORMATION
Traces show that additional null values are sent to the host. For example, the following SNA Application trace shows that 16 additional bytes of null data are sent to the host. PVI  -- PVI  13000003->0302F6B1 LU 6.2 PVI                     MSGID:SWAT   MSGTYP:PRFLS PVI PVI   Header at address 10A8437C, 1 elements PVI  0B050000 00000500 42000000 0100E40F     <........B.....U.> PVI PVI   Element at address 11471920, start 13, end 78 PVI  270502FF 0003D100 0004C3C4 D9C20016     <'.....J...CDRB..> PVI  0DD4E2C6 E34BD3F3 F1F6F3F5 F0F007D5     <.MSFTKL3163500.N> PVI   98BFBB95 00010000 1B12FF                  User data starts here>> F0 C0F0C0F0     <           0.0.0> PVI  C1F30000 00000000 00000000 00000000      PVI  0000                                    <.. > PVI  -- After you apply the hotfix, the trace shows that 7 bytes of data are sent to the host. PVI  -- PVI  06000003->0302E4B1 LU 6.2 PVI                     MSGID:SWAT   MSGTYP:PRFLS  Sense1:1200 PVI                     Sense2:1011 PVI PVI   Header at address 10A842AC, 1 elements PVI  0B051200 10110500 32000000 0100400F     <........2.....@.> PVI PVI   Element at address 11471DB0, start 13, end 62 PVI  270502FF 0003D100 0004C3C4 D9C20016     <'.....J...CDRB..> PVI  0DD4E2C6 E34BD3F3 F1F6F3F5 F0F007D5     <.MSFTKL3163500.N> PVI   98C7DE92 00010000 0B12FF                  User data starts here>> F0 C0F0C0F0     <           0.0.0> PVI  C1F3                                     PVI  -- The TI WIP internal trace shows that 23 bytes of data are sent to the host.

Note The internal trace shows the byte count as a hexadecimal value instead of as a decimal value. 508 00000de4   14006 LU 6.2 Transport Send entered, 0x00000017 bytes to send 508 00000de4   14042 LU 6.2 Transport Send Calling SendData. 508 00000de4   14064 LU 6.2 Transport SendData Entry. 508 00000de4   14064 LU 6.2 Transport SendData Issuing APPC Send verb. 508 00000de4   14064 LU 6.2 Transport SendData Exit S_OK. 508 00000de4   14007 LU 6.2 Transport Send exited normally After you apply the hotfix, the TI WIP internal trace shows that 7 bytes are sent to the host. 600 0000026c   14006 LU 6.2 Transport Send entered, 0x00000007 bytes to send 600 0000026c   14042 LU 6.2 Transport Send Calling SendData. 600 0000026c   14064 LU 6.2 Transport SendData Entry. 600 0000026c   14064 LU 6.2 Transport SendData Issuing APPC Send verb. 600 0000026c   14064 LU 6.2 Transport SendData Exit S_OK. 600 0000026c   14007 LU 6.2 Transport Send exited normally The TI object that was created for this sample is a Microsoft .NET Framework-based TI WIP object. This object consists of a Structure and three arrays. The Structure contains three count fields. The arrays are Data Tables that each consist of one string element. The arrays may each have up to eight elements, depending on the value of the count fields. In the sample trace earlier in this section, the data converts as follows.

The COBOL data definition for this sample data is as follows. 01 MYCALL-INPUT-AREA. 05 PARAMETER1 * STRUCTURE 10 STRUCT1. 15 COUNT1                   PIC S9(2) DISPLAY. 15 COUNT2                   PIC S9(2) DISPLAY. 15 COUNT3                   PIC S9(2) DISPLAY. 15 MEMBER1. * DATA TABLE (VARIABLE NUMBER OF ROWS). 20 DATATABLE1 OCCURS 8 TIMES DEPENDING ON COUNT1. 25 COLUMN1          PIC X.                   15  MEMBER2. * DATA TABLE (VARIABLE NUMBER OF ROWS). 20 DATATABLE2 OCCURS 8 TIMES DEPENDING ON COUNT2. 25 COLUMN1          PIC X.                   15  MEMBER3. * DATA TABLE (VARIABLE NUMBER OF ROWS). 20 DATATABLE3 OCCURS 8 TIMES DEPENDING ON COUNT3. 25 COLUMN1          PIC X. When you are using TCP/IP, network traces also show that additional null characters are sent to the host. Before you apply the hotfix, the TI WIP traces show that 23 bytes of data are sent to the host. 508 00000c38   18007 TCP Transport Send entered, 23 bytes to send 508 00000c38   18085 TCP Transport Send: RE Type=1, Server Mode=256. 508 00000c38   18040 TCP Transport SendCICS entered, 23 bytes to send After you apply the hotfix, the TI WIP traces show that 7 bytes of data are sent to the host. 600 00000f20   18007 TCP Transport Send entered, 7 bytes to send 600 00000f20   18085 TCP Transport Send: RE Type=1, Server Mode=256. 600 00000f20   18040 TCP Transport SendCICS entered, 7 bytes to send

Turn on tracing
To capture traces, use the following methods. By default, the trace files are saved in the following folder:

Program Files\Microsoft Host Integration Server\Traces

SNA Application traces

 * 1) Click Start, click Run, and then type snatrace.
 * 2) Click to select SNA Application, and then click Properties.
 * 3) Click the Message Trace tab, click to select the LU 6.2 Messages check box, and then click OK.

TI WIP traces

 * 1) Open TI Manager.
 * 2) Expand Transaction Integrator (Configuration).
 * 3) Right-click Windows Initiated Processing, and then click Tracing.
 * 4) In the Trace Category pane, click Transport to enable all Transport Trace options.
 * 5) Click to select the Make Trace settings effective immediately check box.
 * 6) Click OK.

Turn off tracing
After you have captured the traces, use one of the following methods to turn off tracing.

SNA Application traces
<ol> <li>In the SNA Trace Utility dialog box, click Clear All Traces.</li> <li>When you receive the following message, click Yes:

All trace settings will be cleared. Are you sure?

</li> <li>Click OK to close the SNA Trace Utility dialog box.</li></ol>

TI WIP traces

 * 1) In TI Manager, right-click Windows Initiated Processing, and then click Tracing.
 * 2) Click to clear all Trace Category check boxes.
 * 3) Click Transport to clear all Transport Trace options.
 * 4) Verify that the Make Trace settings effective immediately check box is selected.
 * 5) Click OK.
 * 6) Close TI Manager.

For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:

824684 Description of the standard terminology that is used to describe Microsoft software updates

Keywords: kbbug kbfix kbqfe kbpubtypekc kbhotfixserver kbhis2004 KB903649

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.