2 Replies Latest reply on Aug 1, 2016 8:42 AM by Steve Cupp

    NSH IF statement question

    Steve Cupp

      I would like to expand this:

       

      #Decide what group to apply

      if [ "${target_server[1,2]}" = "SB" ] ; then

      chosen_group=$group_2

      else

      chosen_group=$group_1

      fi

       

      Into an IF that can check 5 conditions

       

      "${target_server[1,2]}" = "SB"

      "${target_server[1,2]}" = "NO"

      "${target_server[1,6]}" = "UTHDCH"

      "${target_server[1,6]}" = "UTHDAT"

      "${target_server[1,6]}" = "UTHDSP"

       

      I could run independent IF statements, but that runs the risk of not matching any.

      All help will be appreciated