0

Facing error while exporting customer main file

error view

Help to solve this issue...

1
  • I think one of your modules add extra filter type for customer attribute, but we cannot see witch one because you cut the error. Commented Jan 23, 2020 at 11:39

1 Answer 1

0

Finally, got the error Throwing error because of a custom customer attribute created by code.

I removed that attribute using InstallData.php script

<?php
 namespace Custom\Module\Setup;

  use Magento\Eav\Setup\EavSetup;
  use Magento\Eav\Setup\EavSetupFactory;
  use Magento\Framework\Setup\InstallDataInterface;
  use Magento\Framework\Setup\ModuleContextInterface;
  use Magento\Framework\Setup\ModuleDataSetupInterface;
  use Magento\Customer\Model\Customer;

 class InstallData implements InstallDataInterface
 {
  private $eavSetupFactory;

   public function __construct(EavSetupFactory $eavSetupFactory) 
   {
    $this->eavSetupFactory = $eavSetupFactory;
   }

   public function install(ModuleDataSetupInterface $setup, ModuleContextInterface $context)
   {
    $setup->startSetup();

    $eavSetup = $this->eavSetupFactory->create(['setup' => $setup]);
    $eavSetup->removeAttribute(Customer::ENTITY, 'attribute_code_here');

    $setup->endSetup();
    }
 } 

reason for posting answer here Hope it will help to someone who will face and facing same issues.

Happy Coding!!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.