That is, don't replace non-alphanumerics with a space. This matches the
behavior of Formatter::RemoveDiacriticsAndNonalphanumerics(), which
would be used here except that function would also remove quotes. We
actually discussed not introducing spaces previously, but I made a
mistake and didn't apply the same change to the user's search query:
https://github.com/standardebooks/web/pull/470#discussion_r1929591492
This change fixes queries with compound words like:
`Haycraft-Queen`
and also fixes queries for authors with apostrophes:
`O'Neill`
No changes to existing DBs are necessary because they already have terms
like `haycraftqueen` and `oneill` stored in `IndexableCollections` and
`IndexableAuthors`.
* Replace `EbookUrl` with `EbookId` in `Artworks`
* Add a `FullUrl` member to `Ebook`
Add documentation about when to use it versus Url.
The full URL is also being used as an ID in RSS feeds, so use `FullUrl` there.
* Store an `EbookId` in `Artworks`
The `Validate()` method is correctly setting it to null, but then the
`UPDATE` SQL statement is triggering another call to
`GetIndexableText()`. Without this change, empty strings are being
written to the `IndexableText` column.
This allows the user to run a keyword search and then change the sort
order. `Default` is interpreted as `Relevance` if a query is present,
`Newest` if not.
Having it in the SELECT fields was causing warnings like this:
```
NOTICE: PHP message: PHP Deprecated: Creation of dynamic property Ebook::$RelevanceScore is deprecated in /standardebooks.org/web/lib/Traits/Accessor.php
```
The data in these fields are separate:
* `IndexableText`
* `Title`
* `IndexableAuthors`
* `IndexableCollections`
There are also on indices on each of these fields so that they can have
separate weight in the relevance scoring.