The File in this example is 1100 characters across. You will only define a few columns to simplify the example. Here is the column layout of the EBCDIC file: You will need to create a Flat File Connection in the connection manager of your package. Set the Format to Fixed Width and the Code page to the proper code page of your EBCDIC file. NTFS file systems (and only NTFS file systems) support 'Alternate Data Streams' (ADS). These are basically 'invisible' files that attach themselves to existing files. For example, when you enable 'Thumbnails mode' in Windows Explorer, the thumbnail is sometimes stored in an ADS. Unfortunately, this can take up a lot of disk space - and the user. If you try to view an EBCDIC file with a standard ASCII file viewer/editor (eg, notepad), the text will appear as a stream of unprintable control characters. For example, the EBCDIC code for the number zero is hex F0, which is not a printable character in ASCII. When V opens a file, it automatically tries to determine if it is ASCII or EBCDIC.
EBCDIC stands for Extended Binary Coded Decimal Interchange Code, and is the character set used by most IBM mainframes to store documents (in preference to the more commonly used ASCII character set).
If you try to view an EBCDIC file with a standard ASCII file viewer/editor (eg, notepad), the text will appear as a stream of unprintable control characters. For example, the EBCDIC code for the number zero is hex F0, which is not a printable character in ASCII.
When V opens a file, it automatically tries to determine if it is ASCII or EBCDIC. If a file is EBCDIC, EBC will be displayed on the bottom status bar.
If an EBCDIC file is incorrectly displayed as ASCII, you can view it as EBCDIC by pressing Alt+B (or selecting EBCDIC from the View menu).
Once in EBCDIC mode, you may modify EBCDIC viewing options by selecting EBCDIC Options from the View menu, or by clicking on EBC in the status bar.
V views EBCDIC files by mapping each EBCDIC character to the ASCII equivalent before displaying. However, there are at least 6 incompatible versions of EBCDIC (all having non-contiguous letter sequences and missing punctuation characters). In order to support all of these mappings (and more), V defines a default mapping which can then be modified in the EBCDIC tab of the Preferences.
V supports files with variable length records (RECFM=V) and fixed length records (RECFM=F).
Click here for further details on viewing EBCDIC files.
Hex/EBCDIC edit mode works almost identically to hex edit with the exception that it converts EBCDIC data for viewing purposes only and show it as ASCII. The content of the file will not be modified, however the right column that shows the ASCII representation in hex mode will show the data converted to ASCII from EBCDIC.
While in this mode, editing in the ASCII area will allow data to be entered as ASCII and automatically converted to EBCDIC in the file. Editing in the hex area allows data to be entered directly as hex and the ASCII representation (converted from EBCDIC) will be shown in the ASCII area.
Find/Replace in this mode will allow ASCII strings to be used and correctly found/replaced according to the settings in the Find/Replace dialog box. Regular expressions, however, cannot be used in this mode, as the results would be indeterminate.
Ebcdic File Viewer Download
See also: