Page 1 of 1

Build Procedure Search not filtering records

Posted: Fri Jan 15, 2021 6:55 pm
by chpwebmaster
When I run a search under Build Procedure Browse form it highlights my search in red as normal but is not filtering out the non matching records.

Thanks

Re: Build Procedure Search not filtering records

Posted: Fri Jan 15, 2021 6:57 pm
by kev1n
Hi,

Can you show the Browse SQL?

Press CTRL+SHIFT+I in nuBuilder 4.5 or enter nuCurrentProperties().browse_sql in the developer console.

Re: Build Procedure Search not filtering records

Posted: Fri Jan 15, 2021 8:26 pm
by chpwebmaster
SELECT zzzzsys_php_id,sph_code,sph_description,sph_group,CONCAT(sfo_code, ' - ', sfo_description)
FROM zzzzsys_php LEFT JOIN zzzzsys_form ON zzzzsys_form_id = sph_zzzzsys_form_id
WHERE (sph_system != '1' || sph_system IS NULL) or '#nuDevMode#' = '1' AND ( (CONVERT(sph_code USING utf8) LIKE "%Billing%" OR CONVERT(sph_description USING utf8) LIKE "%Billing%" OR CONVERT(sph_group USING utf8) LIKE "%Billing%" OR CONVERT(CONCAT(sfo_code, ' - ', sfo_description) USING utf8) LIKE "%Billing%") )
ORDER BY sph_code"

Re: Build Procedure Search not filtering records

Posted: Sat Jan 16, 2021 6:26 am
by kev1n
Enclose the WHERE statement with brackets to make it work:

SELECT * FROM zzzzsys_php
LEFT JOIN zzzzsys_form ON zzzzsys_form_id = sph_zzzzsys_form_id
WHERE ((sph_system != '1' || sph_system IS NULL) or '#nuDevMode#' = '1')
ORDER BY sph_code