Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
There is a fair amount of inconsistency in the implementation of the database calls in the code. To improve maintainability, we should consistently use placeholders in the queries and fill them with the array argument to db_query rather than filling them in a string format above the call to the query.
To improve portability across databases, we should make sure that all inserts and updates are using dynamic queries rather than static queries. See https://www.drupal.org/node/310080
Comments
Comment #1
berenddeboer CreditAttribution: berenddeboer commented