Hello everyone! Is there a way to get rid of empty lists? I attempted to use `reject(a!isNullorEmpty, RESULT)`, but I encountered the following error: (Image 2).
Image 2
Discussion posts and replies are publicly visible
Did you give a!flatten a try?
docs.appian.com/.../fnc_array_a_flatten.html
Yes, but I need to preserve the inner list of tasks, and after using `a!flatten`, I obtain a general list of tasks. Is there a way to preserve the lists and eliminate the empty ones?
Appian is bad at supporting list of list, unless you involve a map. You can remove the empty values directly when you are building this output using the reject() function or adding an if() condition to check if the value is nullorempty, if yes, then just add {} as the output for that iteration. Appian cannot print in a list unless all are {}