Replace deprecated db_* functions
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #2872725. -->
Reported by: [alex_optim](https://www.drupal.org/user/3317601)
>>>
<p>Replace deprecated db_* methods for work with database.</p>
<p>db_select details - <a href="https://api.drupal.org/api/drupal/core/includes/database.inc/function/db_select/8.8.x">https://api.drupal.org/api/drupal/core/includes/database.inc/function/db_select/8.8.x</a></p>
<p>The deprecation message details are:</p>
<ul>
<li>7x db_select() is deprecated in Drupal 8.0.x and will be removed before Drupal 9.0.0. Instead, get a database connection injected into your service from the container and call call select() on it. For example, $injected_database->db_select($table, $alias, $options); See <a href="https://www.drupal.org/node/2993033">https://www.drupal.org/node/2993033</a></li>
<li>2x db_query_range() is deprecated in Drupal 8.0.x and will be removed before Drupal 9.0.0. Instead, get a database connection injected into your service from the container and call queryRange() on it. For example, $injected_database->queryRange($query, $from, $count, $args, $options). See <a href="https://www.drupal.org/node/2993033">https://www.drupal.org/node/2993033</a></li>
<li>1x db_like() is deprecated in Drupal 8.0.x and will be removed before Drupal 9.0.0. Instead, get a database connection injected into your service from the container and call escapeLike() on it. For example, $injected_database->escapeLike($string). See <a href="https://www.drupal.org/node/2993033">https://www.drupal.org/node/2993033</a></li>
<li>1x: db_query() is deprecated in drupal:8.0.0. It will be removed before drupal:9.0.0. Instead, get a database connection injected into your service from the container and call query() on it. For example, $injected_database->query($query, $args, $options). See <a href="https://www.drupal.org/node/2993033">https://www.drupal.org/node/2993033</a></li>
</ul>
> Related issue: [Issue #3042575](https://www.drupal.org/node/3042575)
issue