in reply to Variable/multiple matches using grep

Seems like we need more info to help you. Can you post more code?
What is @data? What are $one, $two, $three, $four?
What are the requirements for @result?
  • Comment on Re: Variable/multiple matches using grep

Replies are listed 'Best First'.
Re^2: Variable/multiple matches using grep
by Anonymous Monk on Aug 14, 2006 at 12:01 UTC
    What is @data?
    @data is the contents of the csv file in an array.
    What are $one, $two, $three, $four?
    This is the incoming data form the four drop downs in a html page
    What are the requirements for @result?
    A simple specific match against the incoming data and the CSV data. If drop downs $one and $four have been selected I want to display the reults.The data is mostly numerical

    Testing against constent incoming data (for example $one $two $three $four) is fine as I can match the incoming data against where I want to look for it in the CSV @data and I know there is always something incoming.
    But I don't know how to do this for say $one and $two or $two and $four etc which is why I was looking at grep.