Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Sort Order EBCDIC - In UNIX

by Inca (Initiate)
on Nov 20, 2005 at 21:29 UTC ( [id://510285]=perlquestion: print w/replies, xml ) Need Help??

Inca has asked for the wisdom of the Perl Monks concerning the following question:

We are rehosting applications from Mainframe to UNIX. How to achieve EBCDIC sort order in UNIX. Is there a way to set LC_COLLATE and enforce PERL sort to use EBCDIC order? Another option i tried is to convert the ASCII file into EBCDIC (using convert EBCDIC functions), sort and convert it back to ASCII (using convert EBCDIC functions). Doesn't seem to work.

Replies are listed 'Best First'.
Re: Sort Order EBCDIC - In UNIX
by GrandFather (Saint) on Nov 20, 2005 at 21:43 UTC

    shouldn't that be the other way around: EBCDIC -> ASCII, sort, ASCII -> EBCDIC?


    DWIM is Perl's answer to Gödel
      Just as you can find it described here.

      Cheers,
      PerlingTheUK
Re: Sort Order EBCDIC - In UNIX
by Anonymous Monk on Nov 21, 2005 at 06:49 UTC
    Try use locale?
Re: Sort Order EBCDIC - In UNIX
by converter (Priest) on Nov 21, 2005 at 12:20 UTC
    If the file is stored in "ASCII" (probably not ASCII, but an 8-bit character set) then you should sort for that character set, not EBCDIC.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://510285]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (3)
As of 2024-04-26 04:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found