how to write PL/SQL function
Posted on 2008-10-02
How to do a pl/sql function that takes two strings representing a list of
numbers separated by commas and returns a string representing the list
of each nth element added together. You don't know how long the list
will be, but assume it has to fit in a PL/SQL varchar2.
add_nums('1,2,3,4','3,4,5,6') -> '4,6,8,10'
add_nums('1,2,3','15,14,13') -> '16,16,16'
It should fail gracefully when the lengths of the two lists are not