Q
Problem solve Get help with specific problems with your technologies, process and projects.

Export an iSeries file

I'm trying to export an iSeries file --via FTP to my PC -- to use it with Excel. I'm having trouble accomplishing...

this. I have to separate the data with a character, i.e. semi column. I then have to transform all the data from numeric to alphanumeric, and the exported file to .txt. Then, the end-user has to transform it into an Excel file, which is difficult on them. How can I accomplish this automatically without all the manipulations?

It is possible to automate the process for sending files to Excel using CPYTOIMPF. The command CPYTOIMPF "flattens" the file and adds all of the required characters, semicolon etc.

For example:

CPYTOIMPF FROMFILE(MYLIB/MYFILE)
TOSTMF('/tmp/excel.csv')
RCDDLM(*CRLF)
DTAFMT(*DLM)

This will copy myfile to the stream file named excel.csv. After FTPing excel.csv it will be opened automatically by Excel (double click on it).

==================================
MORE INFORMATION ON THIS TOPIC
==================================

Ask your systems management questions--or help out your peers by answering them--in our live discussion forums.

The Best Web Links: Tips, tutorials and more.

Check out this Search400.com Featured Topic: Networking and the iSeries

PC/Windows connectivity expert Shahar Mor is available to answer your toughest networking questions. Ask Shahar a question or read his previously answered questions here.


Dig Deeper on FTP

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchDataCenter

Close