Troubleshooting
Problem
This document explains a option for CWBTFR.INI that will allow Data Transfer users to fine tune the formatting of numeric data that is converted to character data using the "Data Transfer to iSeries" property of "Allow Numeric Data in Character Columns to be Converted to Character Data."
Resolving The Problem
Summary
iSeries Access V5R3 APAR SE20069 introduced new function for Data Transfer that is controlled with a CWBTFR.INI entry. The entry will look similar to the following:
[Client Access Data Transfer]
ExcelNumericFormatter=%.10G
Details
This change will allow the user to define a format specification for Excel Numbers (which Excel stores as Doubles) when used in conjunction with the Allow numeric data in character columns to be converted to character data option of IBM iSeries Access for Windows Data Transfer to iSeries.
The following steps are required to activate this change:
1. | End all instances of Data Transfer and Excel. |
2. | Ensure the latest V5R3/V5R4 iSeries Access service pack is applied to the PC in question. |
3. | Modify cwbtfr.ini. This file is located in c:\WINNT on WinNT and Win2000 and in c:\WINDOWS on WinXP. If the file does not exist on the PC, create the file using NotePad and save it in the directory where Windows is installed. Make sure the first line in the file is: [Client Access Data Transfer] If the file does exist, add the following line: ExcelNumericFormatter=%.10G In this example, the field on the host is defined as a CHAR(10) and the numbers in Excel range up to 10 digits (for example, 1234567890). Without this format specification, the numbers are converted to scientific notation with possible rounding. With this format specification, the numbers are converted to the form 1234567890. As defined at the URL supplied above, the format specification must be in the form of: %[flags] [width] [.precision] [{h | l | I64 | L}]type The maximum length is 20 characters. Only 1 format specification is allowed. If the Excel spreadsheet has a combination of different numerical value formats (i.e 123456, 1234.56, 123456.1234), an ideal format specification may not be possible. |
New Format Testing Tool:
A program to test format specifications has also been supplied. To use this program, do the following:
1. | Start a COMMAND (DOS) session. |
2. | Run the following example DOS command: cwbtftstfmt 1234567890 %.10G |
Historical Number
376612299
Was this topic helpful?
Document Information
Modified date:
18 December 2019
UID
nas8N1015562