cat update_product_attributes_using_sql.sql update catalog_product_entity_int — select * from catalog_product_entity_int set catalog_product_entity_int.value = 1 where (catalog_product_entity_int.attribute_id = 97) and catalog_product_entity_int.entity_id = ( select entity_id from ( SELECT product.entity_id as entity_id FROM bitnami_magento.catalog_product_entity product inner join catalog_product_entity_decimal price on price.entity_id = product.entity_id and (price.attribute_id in (78)) inner join catalog_product_entity_int status_t on (status_t.entity_id = product.entity_id) and (status_t.attribute_id=97) where …
Category: Magento 2
Magento 2
Aug 06
Magento 2: Clear Images in database
truncate table bitnami_magento.catalog_product_entity_gallery; truncate table bitnami_magento.catalog_product_entity_media_gallery_value; truncate table bitnami_magento.catalog_product_entity_media_gallery_value_to_entity; truncate table bitnami_magento.catalog_product_entity_media_gallery_value_video; no warranty given as is
Aug 06
Magento 2: Update data for a custom product attribute
use bitnami_magento; SELECT * FROM bitnami_magento.catalog_product_entity_varcharwhere ( attribute_id = 73 ) — and (value = ”)limit 10 replace into bitnami_magento.catalog_product_entity_varchar (attribute_id, store_id, entity_id, value )SELECT 181, 0, product.entity_id, left(concat(“https://www.amazon.com/s?k=”, product.value),255)FROM bitnami_magento.catalog_product_entity_varchar productinner join catalog_product_entity_int status_t on ( status_t.entity_id = product.entity_id ) and ( status_t.attribute_id = 97 and status_t.value = 1 )where (product.attribute_id=73) — and (value …
Aug 06
Magento 2: Misc. Image related SQLs
select * from bitnami_magento.catalog_product_entity_media_gallery_value_to_entity where value_id in (232574, 242521) — 232574, 242521 select * from bitnami_magento.catalog_product_entity_media_gallery_value_to_entity where value_id in (232574, 242521) — where value like ‘%ud6vtf2a_5ezdxueqvnr%’ –select * from bitnami_magento.catalog_product_entity_media_gallery_value_to_entity select * from bitnami_magento.catalog_product_entity_media_gallery — where value_id in (237733, 237734) where value like ‘%ud6vtf2a_5ezdxueqvnr%’ update bitnami_magento.catalog_product_entity_media_gallery set value = ‘/u/d/ud6vtf2a_5ezdxueqvnr1dyny_1.jpeg’ where value = ‘/u/d/ud6vtf2a_5ezdxueqvnr1dyny.jpeg’ and …
Aug 06
Magento 2: Deactivate Products without images
update catalog_product_entity_int — select * from catalog_product_entity_int set catalog_product_entity_int.value = 2 where (catalog_product_entity_int.attribute_id = 97) and catalog_product_entity_int.entity_id in ( select entity_id from ( Select distinct(product.entity_id) FROM bitnami_magento.catalog_product_entity product left join catalog_product_entity_media_gallery_value_to_entity valentity on valentity.entity_id = product.entity_id left join catalog_product_entity_media_gallery image on image.value_id = valentity.value_id and (image.attribute_id in (90)) inner join catalog_product_entity_int status_t on (status_t.entity_id = …
Dec 06
Administering Magento 2 on AWS Platform
Varnish: Configuring Varnish Server i.e. a Cache Server https://varnish-cache.org/docs/5.1/reference/varnishd.html#http-resp-hdr-len /opt/bitnami/varnish/varnishd varnishd [-a address[:port][,PROTO]] [-b host[:port]] [-C] [-d] [-F] [-f config] [-h type[,options]] [-I clifile] [-i identity] [-j jail[,jailoptions]] [-l vsl[,vsm]] [-M address:port] [-n name] [-P file] [-p param=value] [-r param[,param…]] [-S secret-file] [-s [name=]kind[,options]] [-T address[:port]] [-t TTL] [-V] [-W waiter] [-x parameter|vsl|cli|builtin] [-?] — …
Dec 02
Magento 2 : installation/configuration/operation issues and Solutions
"The Component Dependency Check status never changes. In some cases, the status of the Component Dependency Check doesn’t change, even after you try to correct issues. In that case, you can either delete or rename files named <magento_root>/var/.update_cronjob_status and <magento_root>/var/.setup_cronjob_status and try running the Component Manager again." https://devdocs.magento.com/guides/v2.3/comp-mgr/trouble/cman/component-depend.html
Nov 30
Mysql error after upgrading magento 2.3.2 to 2.3.3
Solution to: SQLSTATE[HY000]: General error: 1419 You do not have the SUPER privilege and binary logging is enabled (you might want to use the less safe log_bin_trust_function_creators variable), query was: CREATE TRIGGER trg_catalog_product_entity_after_insert AFTER INSERT ON catalog_product_entity FOR EACH ROW BEGIN INSERT IGNORE INTO `scconnector_google_feed_cl` (`entity_id`) VALUES (NEW.`entity_id`); END Sol: mysql -u root -p set …
Nov 30
Update Magento 2 to the latest version
Update Magento 2 to the latest version—https://devdocs.magento.com/guides/v2.3/comp-mgr/cli/cli-upgrade.html Work with Github large file system —install: Git-lfs: https://help.github.com/en/github/managing-large-files/installing-git-large-file-storage —How to work with: https://help.github.com/en/github/managing-large-files/configuring-git-large-file-storage Sure, had to deal with i.e. work with By Sayed Ahmed BSc. Eng. in Comp. Sc. & Eng. (BUET) MSc. in Comp. Sc. (U of Manitoba, Canada) MSc. in Data Science and Analytics (Ryerson …
Nov 08
Reindex magento data using PHP (Shell) and Command Line
You can go to the shell folder, and run the following to reindex everything php indexer.php –reindexall Magento 2 has similar command line features. php bin/magento indexer:reindex — To reindex individually php yourmagentofolder/shell/indexer.php -reindex catalog_product_attribute php yourmagentofolder/shell/indexer.php -reindex catalogsearch_fulltext php yourmagentofolder/shell/indexer.php -reindex catalog_category_flat php yourmagentofolder/shell/indexer.php -reindex cataloginventory_stock php yourmagentofolder/shell/indexer.php -reindex catalog_category_product php yourmagentofolder/shell/indexer.php -reindex catalog_product_price …