Files
danbooru/app/logical
evazion 9759701071 search: add way to search array attributes by regex.
Add a `where_any_in_array_matches_regex` method and expose it to the API:

 * https://danbooru.donmai.us/artists?search[any_other_name_matches_regex]=^blah
 * https://danbooru.donmai.us/wiki_pages?search[any_other_name_matches_regex]=^blah
 * https://danbooru.donmai.us/saved_searches?search[any_label_matches_regex]=^blah

In SQL, this does `WHERE '^blah' ~<< ANY(other_names)`, where `~<<` is a
custom operator based on the `~` regex match operator, but with the
arguments reversed. This allows it to be used with the ANY(array) operator.

See also:

* https://stackoverflow.com/a/22101172
* https://www.postgresql.org/docs/current/sql-createfunction.html
* https://www.postgresql.org/docs/current/sql-createoperator.html
* https://www.postgresql.org/docs/current/functions-comparisons.html
2021-01-10 02:03:02 -06:00
..
2020-06-16 21:36:15 -05:00
2021-01-04 18:35:50 -06:00
2020-06-16 21:36:15 -05:00
2019-11-09 14:42:30 -06:00
2019-08-01 00:06:18 -05:00
2020-12-31 06:50:10 -06:00
2020-06-16 21:36:15 -05:00
2020-06-16 21:36:15 -05:00
2020-06-16 21:36:15 -05:00