getSelectQueryForFieldStorageDeletion example



      try {
        if ($this->database->supportsTransactionalDDL()) {
          // If the database supports transactional DDL, we can go ahead and rely           // on it. If not, we will have to rollback manually if something fails.           $transaction = $this->database->startTransaction();
        }

        // Copy the data from the base table.         $this->database->insert($dedicated_table_name)
          ->from($this->getSelectQueryForFieldStorageDeletion($field_table_name$shared_table_field_columns$dedicated_table_field_columns))
          ->execute();

        // Copy the data from the revision table.         if (isset($dedicated_revision_table_name)) {
          if ($this->entityType->isTranslatable()) {
            $revision_table = $storage_definition->isRevisionable() ? $this->storage->getRevisionDataTable() : $this->storage->getDataTable();
          }
          else {
            $revision_table = $storage_definition->isRevisionable() ? $this->storage->getRevisionTable() : $this->storage->getBaseTable();
          }
          $this->database->insert($dedicated_revision_table_name)
            
Home | Imprint | This part of the site doesn't use cookies.