You can create a report for the search. For example a report for MySQL:
CREATE PROCEDURE sp_DBR_find_report(in_search varchar(101))
BEGIN
select 'dbr.parameters.show';
select 'dbr.hidecolumns', 'folder_id';
select 'dbr.url', 'index.php?a=editor', '', '[Name]', 'm=folder_id', 'r=report_id', 'show_link=[is_report]>0';
select 'dbr.url', 'index.php?a=editor', '', '[Name]', 'proc=Name', 'show_link=[is_report]==0';
select 'dbr.url', 'index.php', '', '[Location]', 'm=folder_id', 'highlight=report_id';
select r.name, ifnull(r.proc_name, p.SPECIFIC_NAME) as 'Name', fn_report_location(r.proc_name) as 'Location', p.created as 'Created at', r.folder_id, r.report_id, ifnull(r.report_id,0) as 'is_report'
from information_schema.routines p
left join mydbr_reports r on r.proc_name =p.routine_name
where routine_definition like concat('%', in_search, '%' ) and p.routine_schema=database() and p.routine_name not like 'sp_MyDBR%'
union
select r.name, r.proc_name, fn_report_location(r.proc_name), p.created, r.folder_id, r.report_id, ifnull(r.report_id,0)
from mydbr_reports r
join information_schema.routines p on r.proc_name =p.routine_name and p.routine_schema=database()
where r.proc_name = in_search;
END
With function:
CREATE FUNCTION `fn_report_location`(in_procedure varchar(100)) RETURNS text CHARSET utf8
BEGIN
declare v_folder_id int;
declare v_folder_id_orig int;
declare v_depth int;
declare v_breadcrumb text;
declare v_foldername varchar(1024) character set utf8mb4;
select r.folder_id, f.name into v_folder_id, v_breadcrumb
from mydbr_reports r
join mydbr_folders f on r.folder_id=f.folder_id
where r.proc_name = in_procedure;
while (v_folder_id is not null) do
select mother_id into v_folder_id
from mydbr_folders
where folder_id=v_folder_id;
if (v_folder_id is not null) then
select name into v_foldername
from mydbr_folders
where folder_id=v_folder_id;
if (v_foldername is not null) then
select concat(v_foldername, ' → ', v_breadcrumb) into v_breadcrumb;
end if;
end if;
end while;
return v_breadcrumb;
END