Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
Hi I tried the code and the 2nd one is really preferable (I even understand it better than the first option). However, I have been trying to change so that for example I give the code the reference "Cat" and it returns me "Dog". What I mean is that it searches the 2nd row for the position not the first one and I cannot do it yet. I have been reading the Text::CSV_XS file but I find it a bit hard to grasp (I guess beucase I am still a little confused with the Perl way of working/thinking). I understand that I need to make the change in either getline() OR getline_hr_all but not sure where and what. I think all I have to do is make getline read from the 2nd line for example but I don't know how to do it. Any suggestions? Thanks in advance!

EDIT: I figured it out. What i did was instead of using getline() I used getline_all and then all I have to is offset as much as I want. Thank you all, if I have more questions I will feel free to ask :)


In reply to Re^10: Parse .csv file from FTP using Perl by Sherlock Perl
in thread Parse .csv file from FTP using Perl by Sherlock Perl

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (8)
As of 2024-04-19 15:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found