query bind variables

Events happening in the community are now at Drupal community events on www.drupal.org.
crosenblum's picture

I would like a tiny bit help re-writing db_query to use bind variables

Basically I can remember from my oracle days, of the power of bind variables.

As drupal has a lot of queries, that are repeating, with just a change in variables.

For example cache_get function which has a query like:

SELECT SQL_CACHE data, created, headers, expire, serialized FROM drupal_cache_menu WHERE cid = 'links:navigation:page-cid:node:1'

Well i have already added the SQL_CACHE statement, but in addition, i want to replace db_query, so for certain repeated queries, we can use bind variales.

Read more
Subscribe with RSS Syndicate content