Given a Note document with title some_thing, the following cURL requests and NXQL searches return zero results:
curl -X GET '<NUXEO_SERVER>/nuxeo/api/v1/search/lang/NXQL/execute?query=SELECT+%2A+FROM+Document+WHERE+ecm%3Afulltext+%3D+%22some%5C_thing%22' -H 'Nuxeo-Transaction-Timeout: 3' -H 'X-NXproperties: *' -H 'X-NXRepository: default' -H 'content-type: application/json'
curl -X GET '<NUXEO_SERVER>/nuxeo/api/v1/search/lang/NXQL/execute?query=SELECT+%2A+FROM+Document+WHERE+ecm%3Afulltext+%3D+%22some_thing%22' -H 'Nuxeo-Transaction-Timeout: 3' -H 'X-NXproperties: *' -H 'X-NXRepository: default' -H 'content-type: application/json'
curl -X GET '<NUXEO_SERVER>/nuxeo/api/v1/search/lang/NXQL/execute?query=SELECT+%2A+FROM+Document+WHERE+ecm%3Afulltext+%3D+%22some\_thing%22' -H 'Nuxeo-Transaction-Timeout: 3' -H 'X-NXproperties: *' -H 'X-NXRepository: default' -H 'content-type: application/json'
SELECT * FROM Document WHERE ecm:fulltext = "some_thing"
SELECT * FROM Document WHERE ecm:fulltext = "some\_thing"
SELECT * FROM Document WHERE ecm:fulltext = "some%5Fthing"