[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Finding a value in array



I have defined an array named dept which contains the departments. I
want to check if a particular department id is in the array or not. I
want to do something like
IF deptid in dept array
    do something
else
    error
end-if.

Can somebody please tell me how to look up for a value in array.
Is there any SQR built in function to do that?
I know i can retrieve the individual elements in the array using  get
command and
then compare it using the evaluate command. But that's a long exercise
if the array
contains large number of values.

Thanks

KETAN