[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Converting AS400 file with packed Decimal fields to ASCII

Posted on 2004-09-26
7
Medium Priority
?
1,225 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
6 Comments
 
LVL 6

Expert Comment

by:dedy_djajapermana
ID: 12154747
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
ID: 12157684
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 2000 total points
ID: 12157988
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
Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

 
LVL 6

Expert Comment

by:dedy_djajapermana
ID: 12158280
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
ID: 12158401
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
ID: 12158632
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

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

LinkedIn blogging is great for networking, building up an audience, and expanding your influence as well. However, if you want to achieve these results, you need to work really hard to make your post worth liking and sharing. Here are 4 tips that ca…
MSSQL DB-maintenance also needs implementation of multiple activities. However, unprecedented errors can hamper the database management. In that case, deploying Stellar SQL Database Toolkit ensures fast and accurate database and backup repair as wel…
As many of you are aware about Scanpst.exe utility which is owned by Microsoft itself to repair inaccessible or damaged PST files, but the question is do you really think Scanpst.exe is capable to repair all sorts of PST related corruption issues?
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Suggested Courses

873 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