Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Re^3: Renaming Multiple Files with Different Names

by NetWallah (Abbot)
on Nov 02, 2011 at 17:10 UTC ( #935444=note: print w/replies, xml ) Need Help??

in reply to Re^2: Renaming Multiple Files with Different Names
in thread Renaming Multiple Files with Different Names

This may achieve what you are trying to do. Your first column is "$key". If you want the files generated to use this, Just replace the corresponding line with:
$file{$key}{sequence} = $key; # Old stuff was : sprintf '%03d +.tabular', $file{$key}{ID};

            "XML is like violence: if it doesn't solve your problem, use more."

Replies are listed 'Best First'.
Re^4: Renaming Multiple Files with Different Names
by Feral_Akodon (Initiate) on Nov 02, 2011 at 17:30 UTC
    Perfect it worked. Thanks so much NetWallah!

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://935444]
[Corion]: Cosmic37: Ah, see perlfaq4, about How do I compute the intersection of two arrays
[Cosmic37]: I am out of practice; I use Perl for scientific programming for number crunching
[Corion]: Cosmic37: Basically, you read one file into a hash, keyed by your key, and then match the lines from the second file to that hash
[Cosmic37]: note that the two files only have datetimes which may match whereas other data per line is different format in file1 and file2 - is that really intersection?
[jedikaiti]: Hi Monks
[Corion]: Cosmic37: Well, if you want to use only parts of a line for the key, see split or whatever other mechanism to extract the key from the line
[Corion]: Hi jedikaiti!
[Cosmic37]: is there a webpage for full CB for this chat rather than side panel chat?
[Cosmic37]: thank you for advice
[Cosmic37]: peach greets jedi

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (9)
As of 2017-06-29 16:21 GMT
Find Nodes?
    Voting Booth?
    How many monitors do you use while coding?

    Results (672 votes). Check out past polls.