How to display SQL query in Views module
How to display SQL query in Views module
13.04.2015

Below you have instruction how to display full SQL query in Views module in Drupal.

  • Download and enable Devel module
  • Open file views/plugins/views_plugin_query_default.inc
  • In class views_plugin_query_default find method query($get_count = FALSE)
  • In method query() before return add line: dpq($query);

Example code:

Drupal views query SQL

 

How it looks on website:

Drupal views query SQL

Need a team of Drupal and PHP web development experts?

Contact us now!