| 441 | Queries in ''Advanced Search'' `MUST` be performed using ''FCS-QL'' ([#REF_FCSQL FCS-QL]). The Endpoint `MUST` support parsing all of FCS-QL. If an Endpoint does not support a query, i.e. the used operators or layers are not supported by the Endpoint, it `MUST` return an appropriate error message using the appropriate SRU diagnostic ([#REF_LOC_DIAG LOC-DIAG]). |
| 442 | |
| 443 | The Endpoint `MUST` perform the query on the annotation layers that makes the most sense for the user, e.g. if no specific PartofSpeech layer is given with several layers available from the Discovery phase it should use the most generic one. Endpoints `SHOULD` perform the query with case sensitivity as specified in the query which by default is case sensitive. |
| 444 | |
| 445 | Examples of valid FCS-QL queries for ''Advanced Search'' are: |
| 446 | {{{ |
| 447 | "walking" |
| 448 | [token = "walking"] |
| 449 | "Dog" /c |
| 450 | [token = "Dog" /c] |
| 451 | [pos = "NOUN"] |
| 452 | [pos != "NOUN"] |
| 453 | [lemma = "walk"] |
| 454 | "blaue|grüne" [pos = "NOUN"] |
| 455 | "dogs" []{3,} "cats" within s |
| 456 | [z:pos = "ADJ"] |
| 457 | [z:pos = "ADJ" & q:pos = "ADJ"] |
| 458 | }}} |
| 459 | |
| 460 | The qualifiers ''z'' in ''z:pos'' and ''q'' in ''q:pos'' `SHOULD` match an available qualifier attribute value in a ''pos''-''SupportedLayer'' in a discovered ''EndpointDescripion''. |
| 461 | |
| 462 | |
| 463 | '''NOTE''': Endpoints supporting ''Advanced Search'' `MUST` be able to parse all of FCS-QL. If they don't support a certain FCS-QL feature, they `MUST` generate an appropriate error message (see section [#sruCQL SRU/CQL]). If an Endpoint ''only'' supports ''Basic Search'', it `MUST NOT` silently accept queries that include FCS-QL features.\\ |
| 464 | '''NOTE''': FCS-QL layer identifiers are reserved. The Endpoint `MUST` prepend the local prefix '''x-''' to any identifier used outside of the reserved set, e.g., '''x-funky''' for a local identifier '''funky'''. |
| 465 | |