Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Select.php

function Select::compiled

Overrides QueryConditionTrait::compiled

2 calls to Select::compiled()
Select::arguments in core/lib/Drupal/Core/Database/Query/Select.php
Gets a complete list of all values to insert into the prepared statement.
Select::__toString in core/lib/Drupal/Core/Database/Query/Select.php
Implements PHP magic __toString method to convert the query to a string.

File

core/lib/Drupal/Core/Database/Query/Select.php, line 261

Class

Select
Query builder for SELECT statements.

Namespace

Drupal\Core\Database\Query

Code

public function compiled() {
    if (!$this->condition
        ->compiled() || !$this->having
        ->compiled()) {
        return FALSE;
    }
    foreach ($this->tables as $table) {
        // If this table is a subquery, check its status recursively.
        if ($table['table'] instanceof SelectInterface) {
            if (!$table['table']->compiled()) {
                return FALSE;
            }
        }
        if (!empty($table['condition']) && $table['condition'] instanceof ConditionInterface) {
            if (!$table['condition']->compiled()) {
                return FALSE;
            }
        }
    }
    foreach ($this->union as $union) {
        if (!$union['query']->compiled()) {
            return FALSE;
        }
    }
    return TRUE;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal