code: public function getLangColumnNames(GetPropertyOptionsEvent $event)
      {
          if (($event->getPropertyName() !== 'tag_langcolumn')
              || ('tl_metamodel_attribute' !== $event->getEnvironment()->getDataDefinition()->getName())
          ) {
              return;
          }
  
          $table = $event->getModel()->getProperty('tag_table');
          if (0 === \strpos($table, 'mm_')) {
              $attributes = $this->getAttributeNamesFrom($table);
              \asort($attributes);
  
              $sqlKey       = $this->translator->trans(
                  'tl_metamodel_attribute.tag_column_type.sql',
                  [],
                  'tl_metamodel_attribute'
              );
              $attributeKey = $this->translator->trans(
                  'tl_metamodel_attribute.tag_column_type.attribute',
                  [],
                  'tl_metamodel_attribute'
              );
  
              $event->setOptions(
                  [
                      $sqlKey       => \array_diff_key(
                          $this->getColumnNamesFrom($table),
                          \array_flip(\array_keys($attributes))
                      ),
                      $attributeKey => $attributes,
                  ]
              );
  
              return;
          }
          $result = $this->getColumnNamesFrom($table);
          if (!empty($result)) {
              \asort($result);
              $event->setOptions($result);
          }
      }
docs: Retrieve all column names for the current selected table.
  
  @param GetPropertyOptionsEvent $event The event.
  
  @return void