The filterBy property should be an array of strings, not a comma-separated string. Try changing your code to the following:
[filterBy]="['first_name', 'last_name', 'id']"
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
<p-listbox [options]="chatUserList" [(ngModel)]="selectedChatUserDto" [metaKeySelection]="false" [filter]="!loading" filterBy="first_name,last_name,id" filterPlaceHolder="Search user" emptyFilterMessage="No user found" emptyMessage="No Data" (onChange)="onSelectionChange($event)"> <ng-template let-user pTemplate="item"> {{ user?.first_name }} {{ user?.last_name }}
PrimeNg Documentation filterBy = When filtering is enabled, filterBy decides which field or fields (comma separated) to search against.
I want to "filterBy" multiple fields using the "filterBy" property but it's not working.
filterBy="first_name,last_name,id"
Please or to participate in this conversation.