emartech / magento2-extension

Emarsys Magento2 Extension
MIT License
11 stars 9 forks source link

[M2 2.2.8][v1.4] - API subscriber issue #11

Closed nnwk closed 5 years ago

nnwk commented 5 years ago

Hi Guys,

We're trying to upgrade our Emarsys Module to 1.4 but we've an issue on these request : POST /rest/V1/emarsys/subscriptions HTTP/1.1" 500 5807

The following error is :

main.CRITICAL: Report ID: webapi-5ce41fa93c7f1; Message: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'store.website_id' in 'where clause', query was: SELECT `main_table`.*, `shop_store`.`website_id` FROM `shop_newsletter_subscriber` AS `main_table`
 LEFT JOIN `shop_store` ON shop_store.store_id = main_table.store_id WHERE (`subscriber_email` = 'xxxx@mail.com') AND (`customer_id` = 0) AND (`store`.`website_id` IN('1')) {"exception":"[object] (Exception(code: 42): Report ID: webapi-5ce41fa93c7f1; Message: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'store.website_id' in 'where clause', query was: SELECT `main_table`.*, `shop_store`.`website_id` FROM `shop_newsletter_subscriber` AS `main_table`
 LEFT JOIN `shop_store` ON shop_store.store_id = main_table.store_id WHERE (`subscriber_email` = 'xxxx@mail.com') AND (`customer_id` = 0) AND (`store`.`website_id` IN('1')) at /var/www/releases/feed/1075/shop/vendor/magento/framework/Webapi/ErrorProcessor.php:205, Zend_Db_Statement_Exception(code: 42): SQLSTATE[42S22]: Column not found: 1054 Unknown column 'store.website_id' in 'where clause', query was: SELECT `main_table`.*, `shop_store`.`website_id` FROM `shop_newsletter_subscriber` AS `main_table`
 LEFT JOIN `shop_store` ON shop_store.store_id = main_table.store_id WHERE (`subscriber_email` = 'xxxx@mail.com') AND (`customer_id` = 0) AND (`store`.`website_id` IN('1')) at /var/www/releases/feed/1075/shop/vendor/magento/zendframework1/library/Zend/Db/Statement/Pdo.php:235, PDOException(code: 42S22): SQLSTATE[42S22]: Column not found: 1054 Unknown column 'store.website_id' in 'where clause' at /var/www/releases/feed/1075/shop/vendor/magento/zendframework1/library/Zend/Db/Statement/Pdo.php:228)"} []

Our env. is :

We think that is missing prefix on subrequest : AND (store.website_id IN('1'))

Any idea ?

Is the module is ready for production ?

Many thanks :)

Nicolas

iben12 commented 5 years ago

Hi @nnwk,

Thank You for reporting this issue. We put it on our backlog and hopefully it will be resolved in the next release.

The module is in the piloting phase, we're continuously fixing issues that come up with our client's different Magento setups. Please reach out to your Emarsys contact to arrange your participation in the piloting.

Cheers, Bence

nnwk commented 5 years ago

Hi @iben12

Thank you for your quick answer :)

Any idea of time for this bug fix ? We asked our CSM to add our participation in the piloting phase.

Kind regards, Nicolas

iben12 commented 5 years ago

New version was released today to support prefixed database tables.

In case of issues, please re-open this.