diff --git a/core/modules/views/src/Plugin/views/field/EntityField.php b/core/modules/views/src/Plugin/views/field/EntityField.php
index 4c8032d..59b7d2d 100644
--- a/core/modules/views/src/Plugin/views/field/EntityField.php
+++ b/core/modules/views/src/Plugin/views/field/EntityField.php
@@ -230,7 +230,7 @@ public function query($use_groupby = FALSE) {
       unset($fields[$entity_type_key]);
     }
 
-    if ($use_groupby) {
+    if ($use_groupby && !empty($this->options['group_column'])) {
       // Add the fields that we're actually grouping on.
       $options = array();
       if ($this->options['group_column'] != 'entity_id') {
@@ -265,7 +265,7 @@ public function query($use_groupby = FALSE) {
    */
   function add_field_table($use_groupby) {
     // Grouping is enabled.
-    if ($use_groupby) {
+    if ($use_groupby && !empty($this->options['group_column'])) {
       return TRUE;
     }
     // This a multiple value field, but "group multiple values" is not checked.
@@ -344,13 +344,16 @@ protected function defineOptions() {
     $field_storage_definition = $this->getFieldStorageDefinition();
     $field_type = $this->fieldTypePluginManager->getDefinition($field_storage_definition->getType());
     $column_names = array_keys($field_storage_definition->getColumns());
-    $default_column = '';
-    // Try to determine a sensible default.
-    if (count($column_names) == 1) {
-      $default_column = $column_names[0];
-    }
-    elseif (in_array('value', $column_names)) {
-      $default_column = 'value';
+    $default_column = $field_storage_definition->getMainPropertyName() ?: '';
+    // Try to determine a sensible default if none if provided by the field
+    // definition.
+    if (!$default_column) {
+      if (count($column_names) == 1) {
+        $default_column = $column_names[0];
+      }
+      elseif (in_array('value', $column_names)) {
+        $default_column = 'value';
+      }
     }
 
     // If the field has a "value" column, we probably need that one.
diff --git a/core/modules/views/tests/src/Unit/Plugin/field/FieldTest.php b/core/modules/views/tests/src/Unit/Plugin/field/FieldTest.php
index 2b929f3..f658f4d 100644
--- a/core/modules/views/tests/src/Unit/Plugin/field/FieldTest.php
+++ b/core/modules/views/tests/src/Unit/Plugin/field/FieldTest.php
@@ -495,6 +495,71 @@ public function testQueryWithGroupByForBaseField() {
   /**
    * @covers ::query
    */
+  public function testQueryWithGroupByForBaseFieldFailure() {
+    $definition = [
+      'entity_type' => 'test_entity',
+      'field_name' => 'title',
+    ];
+    $handler = new EntityField([], 'field', $definition, $this->entityManager, $this->formatterPluginManager, $this->fieldTypePluginManager, $this->languageManager, $this->renderer);
+    $handler->view = $this->executable;
+    $handler->view->field = [$handler];
+
+    $this->setupLanguageRenderer($handler, $definition);
+
+    $field_storage = $this->getBaseFieldStorage();
+    $this->entityManager->expects($this->any())
+      ->method('getFieldStorageDefinitions')
+      ->with('test_entity')
+      ->willReturn([
+        'title' => $field_storage,
+      ]);
+
+    $table_mapping = $this->getMock('Drupal\Core\Entity\Sql\TableMappingInterface');
+    $table_mapping
+      ->expects($this->any())
+      ->method('getFieldColumnName')
+      ->with($field_storage, 'value')
+      ->willReturn('title');
+    $entity_storage = $this->getMock('Drupal\Core\Entity\Sql\SqlEntityStorageInterface');
+    $entity_storage->expects($this->any())
+      ->method('getTableMapping')
+      ->willReturn($table_mapping);
+    $this->entityManager->expects($this->any())
+      ->method('getStorage')
+      ->with('test_entity')
+      ->willReturn($entity_storage);
+
+    $options = [
+      'group_column' => NULL,
+      'group_columns' => [],
+      'table' => 'test_entity_table',
+    ];
+    $handler->init($this->executable, $this->display, $options);
+
+    $query = $this->getMockBuilder('Drupal\views\Plugin\views\query\Sql')
+      ->disableOriginalConstructor()
+      ->getMock();
+    $query->expects($this->any())
+      ->method('ensureTable')
+      ->with('test_entity_table', NULL)
+      ->willReturn('test_entity_table');
+    // Ensure that we add the title field to the query, if we group by some
+    // other field in the view.
+    $query->expects($this->any())
+      ->method('addField')
+      ->with('test_entity_table', 'title');
+
+    $this->executable->query = $query;
+
+    $handler->query(TRUE);
+
+    $this->assertObjectNotHasAttribute('group_fields', $handler);
+    $this->assertNull($handler->tableAlias);
+  }
+
+  /**
+   * @covers ::query
+   */
   public function testQueryWithGroupByForConfigField() {
     $definition = [
       'entity_type' => 'test_entity',
@@ -555,6 +620,71 @@ public function testQueryWithGroupByForConfigField() {
   }
 
   /**
+   * @covers ::query
+   */
+  public function testQueryWithGroupByForConfigFieldFailure() {
+    $definition = [
+      'entity_type' => 'test_entity',
+      'field_name' => 'body',
+    ];
+    $handler = new EntityField([], 'field', $definition, $this->entityManager, $this->formatterPluginManager, $this->fieldTypePluginManager, $this->languageManager, $this->renderer);
+    $handler->view = $this->executable;
+    $handler->view->field = [$handler];
+
+    $this->setupLanguageRenderer($handler, $definition);
+
+    $field_storage = $this->getConfigFieldStorage();
+    $this->entityManager->expects($this->any())
+      ->method('getFieldStorageDefinitions')
+      ->with('test_entity')
+      ->willReturn([
+        'body' => $field_storage,
+      ]);
+
+    $table_mapping = $this->getMock('Drupal\Core\Entity\Sql\TableMappingInterface');
+    $table_mapping
+      ->expects($this->any())
+      ->method('getFieldColumnName')
+      ->with($field_storage, 'value')
+      ->willReturn('body_value');
+    $entity_storage = $this->getMock('Drupal\Core\Entity\Sql\SqlEntityStorageInterface');
+    $entity_storage->expects($this->any())
+      ->method('getTableMapping')
+      ->willReturn($table_mapping);
+    $this->entityManager->expects($this->any())
+      ->method('getStorage')
+      ->with('test_entity')
+      ->willReturn($entity_storage);
+
+    $options = [
+      'group_column' => NULL,
+      'group_columns' => [],
+      'table' => 'test_entity__body',
+    ];
+    $handler->init($this->executable, $this->display, $options);
+
+    $query = $this->getMockBuilder('Drupal\views\Plugin\views\query\Sql')
+      ->disableOriginalConstructor()
+      ->getMock();
+    $query->expects($this->any())
+      ->method('ensureTable')
+      ->with('test_entity__body', NULL)
+      ->willReturn('test_entity__body');
+    // Ensure that we add the title field to the query, if we group by some
+    // other field in the view.
+    $query->expects($this->any())
+      ->method('addField')
+      ->with('test_entity__body', 'body_value');
+
+    $this->executable->query = $query;
+
+    $handler->query(TRUE);
+
+    $this->assertObjectNotHasAttribute('group_fields', $handler);
+    $this->assertNull($handler->tableAlias);
+  }
+
+  /**
    * @covers ::prepareItemsByDelta
    *
    * @dataProvider providerTestPrepareItemsByDelta
@@ -722,6 +852,60 @@ protected function setupLanguageRenderer(EntityField $handler, $definition) {
       ->willReturn($entity_type);
   }
 
+  /**
+   * @covers ::add_field_table
+   */
+  public function testAddAdditionalFieldTable() {
+    $definition = [
+      'entity_type' => 'test_entity',
+      'field_name' => 'body',
+    ];
+    $handler = new EntityField([], 'field', $definition, $this->entityManager, $this->formatterPluginManager, $this->fieldTypePluginManager, $this->languageManager, $this->renderer);
+    $handler->view = $this->executable;
+    $handler->view->field = [$handler];
+
+    $this->setupLanguageRenderer($handler, $definition);
+
+    $field_storage = $this->getConfigFieldStorage();
+    $this->entityManager->expects($this->any())
+      ->method('getFieldStorageDefinitions')
+      ->with('test_entity')
+      ->willReturn([
+        'body' => $field_storage,
+      ]);
+
+    $table_mapping = $this->getMock('Drupal\Core\Entity\Sql\TableMappingInterface');
+    $table_mapping
+      ->expects($this->any())
+      ->method('getFieldColumnName')
+      ->with($field_storage, 'value')
+      ->willReturn('body_value');
+    $entity_storage = $this->getMock('Drupal\Core\Entity\Sql\SqlEntityStorageInterface');
+    $entity_storage->expects($this->any())
+      ->method('getTableMapping')
+      ->willReturn($table_mapping);
+    $this->entityManager->expects($this->any())
+      ->method('getStorage')
+      ->with('test_entity')
+      ->willReturn($entity_storage);
+
+    $options = [
+      'group_column' => NULL,
+      'group_columns' => [],
+      'table' => 'test_entity__body',
+    ];
+    $handler->init($this->executable, $this->display, $options);
+    $handler->query = $this->getMockBuilder('Drupal\views\Plugin\views\query\Sql')
+      ->disableOriginalConstructor()
+      ->getMock();
+
+    $handler->additional_fields = ['alt', 'title'];
+    $handler->query(TRUE);
+
+    $this->assertEmpty($handler->tableAlias);
+    $this->assertEmpty($handler->aliases);
+  }
+
 }
 
 class FieldTestEntityField extends EntityField {
