softcommerceltd / magento-graphcommerce-cms-sample-data

Other
0 stars 1 forks source link

error on the set:up #3

Open anisagrebi opened 3 months ago

anisagrebi commented 3 months ago

Unable to apply data patch SoftCommerce\GraphCommerceCmsSampleData\Setup\Patch\Data\ModifyCategorySampleData for module SoftCommerce_GraphCommerceCmsSampleData. Original exception message: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'ccev.entity_id' in 'field list', query was: SELECT ccev.entity_id, ea.* FROM catalog_category_entity_varchar AS ccev LEFT JOIN eav_attribute AS ea ON ea.attribute_id = ccev.attribute_id WHERE (ccev.value = 'what-is-new') AND (ccev.store_id = 0) AND (ea.attribute_code = 'url_key') for the Entreprise Edition we have to use the row_id instead of entity_id il the line 45

`public function apply(): void { $connection = $this->moduleDataSetup->getConnection();

    $categoryValueTable = $this->moduleDataSetup->getTable('catalog_category_entity_varchar');

    $select = $connection->select()
        ->from(['ccev' => $categoryValueTable], **'row_id'**)
        ->joinLeft(
            ['ea' => 'eav_attribute'],
            'ea.attribute_id = ccev.attribute_id'
        )
        ->where('ccev.value = ?', 'what-is-new')
        ->where('ccev.store_id = ?', 0)
        ->where('ea.attribute_code = ?', 'url_key');

    if (!$categoryId = $connection->fetchOne($select)) {
        return;
    }`
softcommerceltd commented 3 months ago

Hi, it's not compatible with MC yet but we do plan on introducing the support for it. Allow me a few days for this. Thanks for looking at it!