Procedures can return results to the calling environment in the parameters to the procedure.
See ”Returning results as procedure parameters” in SQL Anywhere Server - SQL Usage.