You've identified two methods (save to variable and save to file) but another reasonable alternative might be to rerun the original search in the other function. Sure it's wasteful but it's easy. Depends on the how long the database search takes and if the extra resources can be justified.
Otherwise, if you want to go the variable approach, you could just add
push @results_1, [@array] after the if statement. If you don't want to deal with arrays of arrays and if you know that your possible results are limited in some way, you could simplify this to something like push @results_1, join('\t',@array) (blindly assuming tab isn't to be found in your output).
These suggestions are a bit sloppy but might be usable for a casual application.