× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



That's the first thing I did, but it didn't work for writing to an sql generated file. I should have written down the CPF message from a couple of weeks ago when I first looked at this, but I didn't.

In any case, putting an SQL view over it works as Luis suggested, so I'm going that route.

Thanks for the suggestion, though!

coy

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Jeff Young
Sent: Wednesday, 23 June, 2010 12:19 PM
To: Midrange Systems Technical Discussion
Subject: Re: Suggestions for Creating Data Files w/Packed Decimals In aLimited Environment

Try adding FMTOPT(*NOCHK) to your CPYF command.
By default, CPYF attempts to map the fields in the from and to files.
This option will tell the CPYF command to ignore the record formats and just copy the data byte for byte without any mapping.

 
Jeff Young
Sr. Programmer Analyst
IBM -e(logo) server Certified Systems Exper - iSeries Technical Solutions V5R2 
IBM  Certified Specialist- e(logo) server i5Series Technical Solutions Designer V5R3
IBM  Certified Specialist- e(logo)server i5Series Technical Solutions Implementer V5R3
  
 






________________________________
From: Coy Krill <coyk@xxxxxxxxxx>
To: midrange-l@xxxxxxxxxxxx
Sent: Wed, June 23, 2010 2:09:29 PM
Subject: Suggestions for Creating Data Files w/Packed Decimals In a Limited Environment

I have data file coming over from a zSeries that I need to import some
of the segment data from.  The files are zipped and once I determine the
record length, I am uploading them into an iSeries file with a single
character data field of the appropriate length. After that I want to use
CPYF to selectively copy different records (the records are of fixed
width, with varying field definitions).



The records I want have packed decimal fields, which is where my problem
begins. I first created a table using SQL with the appropriate layout,
however, CPYF doesn't seem to want to copy data from the essentially
flat file to the SQL defined table. I can create the file in Query,
however, I can't seem to coerce Query into generating a file with packed
decimal fields.



Any suggestions for either forcing Query to write packed decimal fields
or an alternate way of creating a file with the appropriate layout that
CPYF will accept as a target?



Thanks,

coy




************************************************************************
The information in this e-mail is confidential and may be legally
privileged. It is intended solely for the addressee. Access to
this e-mail by anyone else is unauthorized. If you are not the
intended recipient, any disclosure, copying, distribution or any
action taken or omitted to be taken in reliance on it, is prohibited
and may be unlawful. 
***********************************************************************

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.