The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Comp-3 conversion possible with Shell Scripting or PERL? dfran1972 Shell Programming and Scripting 13 02-23-2008 03:51 PM
lftp transmission error help Iversog UNIX for Dummies Questions & Answers 0 06-29-2006 08:02 AM
Problem with comp built for Linux.. Tony Empire UNIX for Dummies Questions & Answers 18 11-18-2004 06:13 PM
comp hardware comparing sk8parkinsaen OS X (Apple) 2 03-22-2004 01:40 AM
direct transmission of files via TCP/IP darkspace High Level Programming 5 08-26-2002 11:00 AM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 02-15-2007
Registered User
 

Join Date: Dec 2006
Posts: 16
Stumble this Post!
COMP-3 File transmission

Guys,

i need to transfer a file which contains both display and comp-3 fields from unix to mainframe. Cyberfusion , FTP doesn't work since they treat display and comp-3 fields same.

Any Solution in this regard will be appreciated.

Thanks,
Sharif.S
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 02-15-2007
...@...
 

Join Date: Feb 2004
Location: NM
Posts: 3,841
Stumble this Post!
Did you set the transfer to binary? What is the source/destination machine? byte order might be a problem. (Endianness)
Reply With Quote
  #3 (permalink)  
Old 02-15-2007
Perderabo's Avatar
Unix Daemon
 

Join Date: Aug 2001
Location: Washington DC Area
Posts: 8,443
Stumble this Post!
Quote:
Originally Posted by sharifhere
FTP doesn't work since they treat display and comp-3 fields same.
I don't see why that would be. A "ascii" transfer from unix to a non-unix box means that a newline character will be replaced with whatever the destination box deems appropriate. With a mainframe, (like dos) it will be replaced with a newline/carriage return combination. Since one byte is replaced with 2 bytes the file will grow in size should this happen. Did it? A unix newline character is hex 0A which is not legal in a comp-3 field. Still since you are not moving text, you should use a binary transfer. And comp-3, aka packed decimal, should bypass endian issues as easily as text does.

Don't be too quick to blame this on the transfer. I would suspect that the unix program which created the data and the mainframe program that is reading the data are not singing from the same songsheet.
Reply With Quote
  #4 (permalink)  
Old 02-15-2007
Registered User
 

Join Date: Dec 2006
Posts: 16
Stumble this Post!
Thanks for ur reply. I tried transferring in binry still the same problem occured. Junk characters replaced the packed fields in the destinaiton file.

Source Machine : Unix (Solaris 9.0)
Destination : Mainframe (OS/390)
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 01:23 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0