DO functions cannot return data directly, but they can declare cursors and those can be accessed after the DO function ends.