I created a stored procedure where it returns the string with a successful message and the number of rows inserted or error messages like file not found or data did not load when executed manually. when I called the same stored procedure with task it shows(task_history) as succeed. and cant find if the data has been loaded or not. it has to be checked manually.
when I referred the following question Snowflake a working procedure is not being successfully executed when calling it within a scheduled task
the procedure and the task has the same owner(owner has global execute task privilege).
but data is being updated both the times during manual and task call of procedure.
how to make the return value appear in task and make the task not executing the successor task if the stored procedure return a error.