Hi Joanna!
It's a little difficult to determine what might be causing the issue without having a better understanding of what field type DS_Barrier, TRIM, and TRAILING are, along with what you're trying to get from the SQL Expression you've created. Here's some documentation with samples of query expressions that you can refer to in the meantime: Standardized SQL functions in ArcGIS Online—ArcGIS Online Help | Documentation. Hope that helps!
Thanks,
Vivien