What is it supposed to 'grab'.
This line; " set %last $5" is always setting %last to whatever is $5 (if there is a $5, otherwise to NULL), so checking "(%last isin $5) is very redundant here. smile