| Computing.Net: Over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to sign up now, it's free! |
using arrays in a while statement ?
|
Original Message
|
Name: hernandez
Date: May 11, 2003 at 01:18:43 Pacific
Subject: using arrays in a while statement ? OS: xp korn shell CPU/Ram: 256
|
Comment: Hi I am trying to run a loop based on an array variable. I have a function that on completion sets the COMPLETE flag to 1. The next function is called and controlled by a while loop which I've had running perfectly without using an array like this: while [ $COMPLETE -ne 1 ] but now I need to know which records have a 'complete status' so I decided to create an array and to use it to control the next loop - so I tried this : while [ $COMPLETE[CURRENT_ROW] -ne 1 ] This is generating an error of 'misplaced subscript in arithmetic expression "1[current_row]" near' can someone tell me what i've done wrong? - and how to get this working........
Report Offensive Message For Removal
|

Post Locked
This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
Go to Unix Forum Home