PERL:How to convert numeric values txt file to PACKED DECIMAL File?


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting PERL:How to convert numeric values txt file to PACKED DECIMAL File?
# 1  
Old 05-20-2009
PERL:How to convert numeric values txt file to PACKED DECIMAL File?

Is there any way to convert numeric values txt file to PACKED DECIMAL File using PERL.

Regards,
Alok
# 2  
Old 05-20-2009
check out Convert::IBM390 at cpan
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Convert a numeric to 2 decimal point value

Hi , I have a file which contains text like A|Mau|Code|12|Detail B|Mau|Code|20|Header I want to write a command using awk which will output A|Mau|Code|12.00|Detail B|Mau|Code|20.00|Header I used a command like awk -F"|" {printf "%s|%s|%s|%.2f|%s",$1,$2,$3,$4,$5}' which does the... (4 Replies)
Discussion started by: LoneRanger
4 Replies

2. UNIX for Dummies Questions & Answers

How to control the decimal poins for the whole .txt file?

Dear all, I have a .txt file with n=400 columns, n=440,000 rows. The file looks like below: -0.0625123454 0.03732424 -0.11293423 ... 0.15651325435 -0.1366346346 -0.28384636 ... ... I want to change all the numbers in the file with n=3 decimal places. I don't know if it is very... (6 Replies)
Discussion started by: forevertl
6 Replies

3. Shell Programming and Scripting

Retain upto 2 decimal point for numeric values

Hi I have a big file with lines like below <tr align="center" bgcolor="SEASHELL"><td>94% </td><td>4.62178 </td><td>73.4375 </td></tr> <tr align="center" bgcolor="SEASHELL"></td><td>97% </td><td>3.2962 </td><td>125 </td></tr> I want to format the file such that i get like below. i.e... (3 Replies)
Discussion started by: ningy
3 Replies

4. Shell Programming and Scripting

How to convert a file containing hex code to decimal using script?

The file contains code like the below and need to convert each one into a decimal 00 00 00 04 17 03 06 01 So the output should come as 0 0 0 4 23 3 6 1 (24 Replies)
Discussion started by: necro98
24 Replies

5. Shell Programming and Scripting

To convert file with decimal to another file with Hexadecimal

I have a text file of alphanumeric values listed one by one. I have to convert them to hexadecimal equivalents for each character seperated by ":" in Unix bash shell script. For example, 12345678 has to be converted to 31:32:33:34:35:36:37:38 (10 Replies)
Discussion started by: mathie
10 Replies

6. Shell Programming and Scripting

How to check if the file contains only numeric values

How to check if the file contains only numeric values. I don't want to read entire file it eats lot of cpu Or any way which consumes less memory n cpu.. Please suggest -S (2 Replies)
Discussion started by: sunilmenhdiratt
2 Replies

7. Shell Programming and Scripting

How to convert a .log file into .txt file under unix??

Hi Friends, I have a .log file generated from a tool(Windows PC) which can be opened using a notepad, but when I tried to view the file in unix (cygwin on my laptop) the file type is showing as binary file, So I am unable to process the file. I need to extract some of the selected text... (3 Replies)
Discussion started by: ks_reddy
3 Replies

8. Shell Programming and Scripting

how to convert data from ASCII to Packed Decimal

Hi All, Please let me know if it is possible to convert data from ASCII to Packed Decimal through Unix? Basically we have ASCII file with numeric data we want to convert that files data to Packed decimal format to send it to main frame. Please let me know if we can do it through unix script.... (1 Reply)
Discussion started by: aloktiwary
1 Replies

9. UNIX for Dummies Questions & Answers

Packed Decimal

How do we create a text file with COBOL "Packed Decimal" value in UNIX ? (1 Reply)
Discussion started by: gaddeg
1 Replies

10. UNIX for Dummies Questions & Answers

Convert "text" to "packed-decimal"?

Is there a way with HP-UX Release 10.20 (but going to HP-UX 11) to convert a regular "text" file to a packed data format (such as is created by a Cobol program)? (2 Replies)
Discussion started by: HuskyJim
2 Replies
Login or Register to Ask a Question