Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. mac9968

    For i in $userarray[@] is one line off

    Thanks LK, thought I needed that..... the EMOTICON made me laugh out loud.[thanks]
  2. mac9968

    For i in $userarray[@] is one line off

    Hello, I have searched the forum, but am unable to find direction on my issue. I have s simple BASH script below #!/bin/bash # ########################### userarray=$(cat test|awk 'BEGIN {FS="\t"}; {print $1}'|sort -u) echo "USERID #of occurances" for i in $userarray[@] do printf...
  3. mac9968

    Build array using Variable

    Not sure if it helps, but is it just as easy to say: for i in sys1 sys2 sys3; do set -A AR$i $(cat /tmp/$i.txt) done to something like: for i in sys1 sys2 sys3; do AR$i=$(cat /tmp/$i.txt) done
  4. mac9968

    Data Mapping with Hashes

    That did it, I change a few things, but this should work. I will format the print a bit, but thank again Travis. I also added the rest of my regions, and code for the <> operator. #!/usr/bin/perl use warnings; use strict; my %region = ( 5 => 'Relay', 70 => 'Chicago', 11 => 'Satsuma', 13 =>...
  5. mac9968

    Data Mapping with Hashes

    Thanks Travis, Please get some sleep, I will give this a try.
  6. mac9968

    Data Mapping with Hashes

    rharsh thank you, I have attached the script i have thus far. I am unable to do the comparative part. Take the input from the file from <> and campare it to the %regions that I have define. After that I would like to report all the regions defined, and the number of times each region showed up...
  7. mac9968

    Data Mapping with Hashes

    Morning all, I have a task that I need to get done, and cant seem to get it together. I have a file that I am read via the <> operator. This files contains simply: 17 21 19 70 99 45 32 25 67 89 90 91 11 10 12 33 34 36 37 several lines of numbers from 1 to 99. In the perl file I am pulling the...
  8. mac9968

    Second file read from Diamond Operator need first line removed

    Feherke, thank you, told you, over thinking it. Sorry for not notating my post. thanks again
  9. mac9968

    Second file read from Diamond Operator need first line removed

    First Thread! Folks, I have a script that is using the diamond operator to read two files that I have specified at the command line. The first file is a standard text, the second file is a CSV file, with a header. My script works if I remove the header before executing, but I would like to...

Part and Inventory Search

Back
Top