Solved

Converting AS400 file with packed Decimal fields to ASCII

Posted on 2004-09-26
7
1,168 Views
Last Modified: 2008-01-09
Team,

I am in need for a suitable tool which can do the converstion from AS400 EBCDIC to Windows ASCII and vis versa from command prompt. I don't have CA and I can't buy expensive tools.

If there is a way to have a direct socket connection (either through ODBC or JDBC) that will be ok but I need the suitable driver and I don't want to buy Microsoft HIS for example.

Appreciate your quick response.

Thanks in advanced
0
Comment
Question by:Jablif
  • 3
  • 2
7 Comments
 
LVL 6

Expert Comment

by:dedy_djajapermana
Comment Utility
hi,

use windows FTP that:
1. do remote execute CPTOIMPF; CPYTOIMPF will convert packed decimal to normal decimal. You can test the command first.
2. GET the result of the CPYTOIMPF

Please let me know if you need example.
0
 

Author Comment

by:Jablif
Comment Utility
Hi Dedy,

Thanks for your reply.

Actually, I appreciate if you give the example so I better execute it.

Thanks again
0
 
LVL 6

Accepted Solution

by:
dedy_djajapermana earned 500 total points
Comment Utility
hi

supposed you have PFILE in library LIBRARY
first, create a folder to contain the temporary converted file, e.g., CRTFLR FTPTMP

on the PC:
create a text file named FTP.SRC with notepad with content like this:
qsecofr
passwordofQSECOFR
quote rcmd CPYTOIMPF FROMFILE(LIBRARY/PFILE) TOSTMF('/qdls/ftptmp/PFILE.csv') MBROPT(*REPLACE) RCDDLM(*CRLF)
get /qdls/ftptmp/PFILE.csv
quit

----end of FTP.src file

then on the command line (assumed that the fTP.src is in the same directory):
C:>ftp -s:ftp.src xxx.xxx.xxx.xxx
(xxx.xxx.xxx.xxx is your as/400 IP address)
the file is downloaded as PFILE.csv in your directory

0
Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

 
LVL 6

Expert Comment

by:dedy_djajapermana
Comment Utility
hi dave,

note that i put cpytoimpf, and ftp the CPYTOIMPF'ed file, not the file with packed field.

dd
0
 

Author Comment

by:Jablif
Comment Utility
Thanks a lot Dedy I will try that then will let you know the result.

Hi Dave,

I have read the mentioned thread but it was talking about either using CA or MS HIS. I don't have them both.

0
 
LVL 14

Expert Comment

by:daveslater
Comment Utility
Hi  dedy_djajapermana

sorry, I did not see that bit. It iis best to go with  dedy_djajapermana  solition and ignore my comment as it will over complicate things

dave

0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Install CPIO 1 159
AS400 Forms 9 97
Comments on the use of ftp server/client on OS/400 AS/400 4 85
Monitoring IBM System x through PRTG 7 100
Restoring deleted objects in Active Directory has been a standard feature in Active Directory for many years, yet some admins may not know what is available.
Find out what Office 365 Transport Rules are, how they work and their limitations managing Office 365 signatures.
This video discusses moving either the default database or any database to a new volume.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now