Users Search acting weird after upgrading to 6.0.0

I upgraded two instances from 5.0.8 to 6.0.0 this weekend. I performed a fresh 6.0.0 installation, imported the database from 5.0.8, and ran make upgrade-database.

I probably missed something because in both instances, the user’s search is not working as expected.

When I search for ‘db’, which is part of a user’s name, it doesn’t work, and it throws the following messages in the logs.

[711] [Mon Jul  7 13:56:04 2025] [warning]: DBD::Pg::st execute failed: ERROR:  invalid input syntax for type integer: ""
CONTEXT:  unnamed portal parameter $8 = '' at /usr/local/share/perl/5.36.0/DBIx/SearchBuilder/Handle.pm line 634. (/usr/local/share/perl/5.36.0/DBIx/SearchBuilder/Handle.pm:634)
[711] [Mon Jul  7 13:56:04 2025] [warning]: RT::Handle=HASH(0x5603ca13d180) couldn't execute the query 'SELECT main.* FROM Users main JOIN Principals Principals_1  ON ( Principals_1.id = main.id )  WHERE (Principals_1.Disabled = ?) AND (Principals_1.PrincipalType = ?) AND (main.EmailAddress ILIKE ? OR main.Name ILIKE ? OR main.RealName ILIKE ?) AND (main.id NOT IN (?, ?) OR main.id != ? AND main.id IS NOT NULL)  ORDER BY main.Name ASC  LIMIT ?' at /usr/local/share/perl/5.36.0/DBIx/SearchBuilder/Handle.pm line 647.
	DBIx::SearchBuilder::Handle::SimpleQuery(RT::Handle=HASH(0x5603ca13d180), "SELECT main.* FROM Users main JOIN Principals Principals_1  O"..., 0, "User", "db%", "db%", "%db%", 1, ...) called at /opt/rt6/sbin/../lib/RT/Handle.pm line 3548
	RT::Handle::SimpleQuery(RT::Handle=HASH(0x5603ca13d180), "SELECT main.* FROM Users main JOIN Principals Principals_1  O"..., 0, "User", "db%", "db%", "%db%", 1, ...) called at /usr/local/share/perl/5.36.0/DBIx/SearchBuilder.pm line 249
	DBIx::SearchBuilder::_DoSearch(RT::Users=HASH(0x5603cc8c8388)) called at /opt/rt6/sbin/../lib/RT/SearchBuilder.pm line 1100
	RT::SearchBuilder::_DoSearch(RT::Users=HASH(0x5603cc8c8388)) called at /usr/local/share/perl/5.36.0/DBIx/SearchBuilder.pm line 630
	DBIx::SearchBuilder::Next(RT::Users=HASH(0x5603cc8c8388)) called at /opt/rt6/share/html/Helpers/Autocomplete/Users line 114
	HTML::Mason::Commands::__ANON__("return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Component.pm line 135
	HTML::Mason::Component::run(HTML::Mason::Component::FileBased=HASH(0x5603ca17f808), "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1302
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1292
	HTML::Mason::Request::comp(undef, undef, undef, "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 955
	HTML::Mason::Request::call_next(RT::Interface::Web::Request=HASH(0x5603cca55610)) called at /opt/rt6/share/html/Helpers/Autocomplete/autohandler line 50
	HTML::Mason::Commands::__ANON__("return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Component.pm line 135
	HTML::Mason::Component::run(HTML::Mason::Component::FileBased=HASH(0x5603cc019e88), "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1302
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1292
	HTML::Mason::Request::comp(undef, undef, undef, "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 955
	HTML::Mason::Request::call_next(RT::Interface::Web::Request=HASH(0x5603cca55610)) called at /opt/rt6/share/html/Helpers/autohandler line 50
	HTML::Mason::Commands::__ANON__("return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Component.pm line 135
	HTML::Mason::Component::run(HTML::Mason::Component::FileBased=HASH(0x5603cacbf830), "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1302
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1292
	HTML::Mason::Request::comp(undef, undef, undef, "return", "id", "term", "db") called at /opt/rt6/sbin/../lib/RT/Interface/Web.pm line 819
	RT::Interface::Web::ShowRequestedPage(HASH(0x5603cbf2f468)) called at /opt/rt6/sbin/../lib/RT/Interface/Web.pm line 472
	RT::Interface::Web::HandleRequest(HASH(0x5603cbf2f468)) called at /opt/rt6/share/html/autohandler line 53
	HTML::Mason::Commands::__ANON__("return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Component.pm line 135
	HTML::Mason::Component::run(HTML::Mason::Component::FileBased=HASH(0x5603ca17e9c8), "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1300
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 1292
	HTML::Mason::Request::comp(undef, undef, undef, "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 481
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 481
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/Request.pm line 433
	HTML::Mason::Request::exec(RT::Interface::Web::Request=HASH(0x5603cca55610)) called at /usr/local/share/perl/5.36.0/HTML/Mason/PSGIHandler.pm line 96
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/PSGIHandler.pm line 96
	HTML::Mason::Request::PSGI::exec(RT::Interface::Web::Request=HASH(0x5603cca55610)) called at /usr/local/share/perl/5.36.0/HTML/Mason/Interp.pm line 342
	HTML::Mason::Interp::exec(undef, undef, "return", "id", "term", "db") called at /usr/local/share/perl/5.36.0/HTML/Mason/PSGIHandler.pm line 59
	eval {...} called at /usr/local/share/perl/5.36.0/HTML/Mason/PSGIHandler.pm line 59
	HTML::Mason::PSGIHandler::invoke_mason(HTML::Mason::PSGIHandler::Streamy=HASH(0x5603c96f7770), HASH(0x5603ccfa9468), HASH(0x5603ccdcf248)) called at /usr/local/share/perl/5.36.0/HTML/Mason/PSGIHandler/Streamy.pm line 52
	HTML::Mason::PSGIHandler::Streamy::__ANON__(CODE(0x5603ccd67080)) called at /usr/local/share/perl/5.36.0/Plack/Util.pm line 339
	Plack::Util::__ANON__(CODE(0x5603cce84650)) called at /usr/local/share/perl/5.36.0/Plack/Util.pm line 339
	Plack::Util::__ANON__(CODE(0x5603ccf3efc0)) called at /usr/local/share/perl/5.36.0/Plack/Handler/FCGI.pm line 149
	Plack::Handler::FCGI::run(Plack::Handler::FCGI=HASH(0x5603ca107a30), CODE(0x5603c973e780)) called at /usr/local/share/perl/5.36.0/Plack/Loader.pm line 84
	Plack::Loader::run(Plack::Loader=HASH(0x5603bed66390), Plack::Handler::FCGI=HASH(0x5603ca107a30)) called at /usr/local/share/perl/5.36.0/Plack/Runner.pm line 279
	Plack::Runner::run(RT::PlackRunner=HASH(0x5603be6bdf78)) called at /opt/rt6/sbin/../lib/RT/PlackRunner.pm line 150
	eval {...} called at /opt/rt6/sbin/../lib/RT/PlackRunner.pm line 150
	RT::PlackRunner::run(RT::PlackRunner=HASH(0x5603be6bdf78)) called at /opt/rt6/sbin/rt-server.fcgi line 165 (/usr/lib/x86_64-linux-gnu/perl-base/Carp.pm:292)

How to fix this?

Thanks.

What does you RT upgrade history look like in the system configuration page?

EDIT: Replaced the screenshots

I just found a bug report related to this issue. I hope this gets fixed soon.

https://rt.bestpractical.com/Ticket/Display.html?id=38036