How to handle French Accent characters with CFF component?

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
jingyu
Participant
Posts: 7
Joined: Mon Jun 11, 2007 11:52 am

Post by jingyu »

I want to add one more info that my DS designer client does not come with NLS installation.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

NLS is not required for the standard latin accent characters. Many times problems with NLS is assumed when the issue is only a display one. Where are you viewing this? There are many EBCDIC implementations and standards out there, but as far as I know they all convert the standard accents the same way, and when you see a "?" in DataStage it usually means "undisplayable".
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Another question, how many binary columns do you have in your file? If just a few, you can let FTP take care of the EBCDIC-ASCII conversion and then reconvert those few COMP columns to EBCDIC and then decode them using the sdk routines into their actual number values.
jingyu
Participant
Posts: 7
Joined: Mon Jun 11, 2007 11:52 am

Post by jingyu »

Are you suggesting to download Mainframe file (having few COMP columns) using ASCII mode? I tried this and I CAN NOT download the file correctly since I can only see first column value (using Datstage data view or open it under Unix) and all other columns value are empty (my COMP column start from 2nd). My FTP defenition is:

Remote File Name: 'DB.MYDATA.UNLD'
Data Representation Type: ascii
Check data against meta data: No
Line Termination: [LF] (Unix Style Termination)
Fixed-width Columns: Yes
Spaces Between Columns: 0
Column Delimiter: ~
Quote Character: "
Escape Character: \
First Line Column Names: No
FTP Data Connection Mode: active
Link Tracing Level: 0
Buffer Length: 4096


Output Columns
MY_Data Char(127)

Target Stages
Sequential File : Source_DATA

Line termination: Unix
Stage uses named pipes: File
First character is Byte Order Mark: Yes
Use UNICODE map: Yes
Stage uses filter commands: No


Input: lnk_ftpDATA_out

Output sequential file stage:

Input from Transformer stage downloadDATA
File name: #SERVERPATH#/ftp/mydata_unld
Delimiter: ~
Quote character: "
First line is column names: No
Omit last new-line: No
Append to existing file: No
Backup existing file: No
Fixed-width columns: Yes
Spaces between columns: 0
Missing columns action: 0
Write timeout: 0
Wait for reader timeout: 0
Default padding: #

If I use command line FTP and using ascii i CAN DOWNLIOAD this mainframe file correctly the COMP columns are non- readable characters. How come DataStage FTP can't download file with COMP columns using ASCII mode? It should have the saem behaviour as normal FTP? Please advise. Thanks.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

You cannot use the method that I suggested using DataStage FTP since that attempts to parse the contents of each line, and since the format is now wrong it won't interpret the column contents correctly.
jingyu
Participant
Posts: 7
Joined: Mon Jun 11, 2007 11:52 am

Post by jingyu »

Are you saying that I should not use DS's FTP plug-in in this case? What is the right way I can test? Thanks.
ArndW wrote:You cannot use the method that I suggested using DataStage FTP since that attempts to parse the contents of each line, and since the format is now wrong it won't interpret the column contents correctl ...
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Right, do not use the DS FTP stage if you aren't converting the file line-by-line. Since it seems you've already used FTP I would stay with that approach; use the EBCDIC() function on the COMP-3 columns to reconvert them to their original binary image and then use the sdk kit routines to make them into useable values.
jingyu
Participant
Posts: 7
Joined: Mon Jun 11, 2007 11:52 am

Post by jingyu »

Does that means I can not use DS FTP plug-in to handle the mainframe file with COMP columns and French accent characters content? The other FTP I was using is just for test to validate DS FTP plug-in. I still want to use DS FTP if possible. Is any option here? How can I use DS FTP plug-in with line-by-line convertion in this situation? Thanks.
Post Reply