I am creating a function that contains the following loop:
While v_start >= v_stop do
set v_msg := concat(v_msg,v_start,v_delimiter);
set v_start := v_start + v_step;
end while;
When I call the function, I pass the following parameter:
select a06_counter_loop(10,-5, -3, '-->') as 'The Loop Output';
It should return:
10-->7-->4-->1-->-2-->-5
But it returned:
10-->7-->4-->1-->-2-->-5-->
My question is that how do I get rid of the last non-number character?
Let me know if you need the entire code for the function.
Thanks, Perri