New answers tagged

1

There is a problem in Magento that it doesn't take price scope into account while loading product EAV attributes. As a solution, you can tweak core code Magento\Eav\Model\ResourceModel\ReadHandler::execute Or remove obsolete data manually how is described below. Product price data is stored in catalog_product_entity_decimal MySQL table. You should delete ...


0

We have the next tables list created for our solution: ecombricks_store__catalog_product_bundle_selection_price ecombricks_store__catalog_product_entity_tier_price ecombricks_store__catalog_product_index_price ecombricks_store__catalog_product_index_price_bundle_idx ecombricks_store__catalog_product_index_price_bundle_opt_idx ...


0

Magento 2.4.x support MySQL 8.


0

if you want to handle the data after order confirmation you can hang on to the sales_order_place_after event through an observer. Here events list: https://www.mageplaza.com/magento-2-module-development/magento-2-events.html Cheers


0

This is happening because of MySQL 8, which by default uses the plugin auth_socket. Applications will most times expect to log in to your database using a password, to do it access the MySQL via root user and run this command: ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root'; Then try to connect using it: mysql -u root -proot ...


0

Try this code echo "<pre>"; $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); //vendor\module\Model\PostFactory $post = $objectManager->Create('\vendor\module\Model\ResourceModel\Post\Collection')->addFieldToFilter('status','pending'); foreach ($post as $key => $value) { //print_r($value->getId()); $...


0

Check if your prepaidModel has a constructor with two underlines (__construct) .If exists check if this is valid method e.g passes all parameters correctly for its parent . This methods calls _construct - with one underline- inside it that initiates correctly your resourceModel. For a _construct (one underline) correct method, check below: https://www....


1

Incase you want to just restore all the products from the backup db. The first steps you can follow is you can now create another backup of your damage DB Now after backup you can truncate all the products and restore all product from the previous db. Truncate Product tables # you can set foreign key checks off SET FOREIGN_KEY_CHECKS = 0; TRUNCATE TABLE `...


0

Follow below steps to update the created_at and update_at columns on saving the data in the table. Create created_at and update_at columns in the database table. ................. <column xsi:type="timestamp" name="created_at" on_update="false" nullable="false" default="CURRENT_TIMESTAMP" comment="...


1

There are multiple possible ways for you to achieve the sync process. Process 1 Call the Magento API's from your external application to collect one time data with pagination, in-order to handle gateway timeout. Write Event observer in Magento to listen any changes for this data and push it to your external application by calling API's of your application. ...


0

How would I check if the store already exists by code? Your approach is correct. Example Code : try { $this->storeRepository->get($storeCode); } catch (NoSuchEntityException $nsee) { // Requested store doesn't exist } Difference between store and group If you will see grid under Stores -> All Stores, you will see three columns Web Site, ...


0

You can create database from the terminal on MAC running MAMP with these steps /Applications/MAMP/Library/bin/mysql -u root -p Enter your password at the prompt to connect to mysql. When connected to MySQL shell, run the code below to create your database. create database magento; exit; Run the magento installation script again


0

After a few hours digging I've realised that I have followed the recommendation of query_cache_type = 0 from MySQLTunerScript as that feature would be removed in Mysql 8.0 By setting query_cache_type = 1 and tuning the query_cache_size value we have now removed the issue.


0

I had this same issue. It turned out to be some extra entries in the "eav_customer_attribute" table. Once I removed these entries the page loaded and worked fine. I also found that this issue caused the customers address to be saved as a new entry on every order.


0

its possible that catalog design or layout update might be using the theme you have deleted, thus you are seeing that error. Right way to do it by magento


0

SOLVED: There was store on 'stores' table that was relating with an 'store_group' that wasn´t there. Changed the ID and reindex worked fine. Note : remove values from the table design_change


0

You want to update the attribute set for a product type: https://www.ubertheme.com/magento2/understanding-magento-2-product-attributes-attribute-sets/#:~:text=Some%20attributes%20are%20built%20into,2%20to%20customize%20your%20products.&text=Attribute%20set%20represents%20a%20list,to%20a%20specific%20product%20family. Check out this question/answer for ...


1

Magento 2 [EE] SQL Query as follows below. To disable products by using SKU. Find the attribute_id value for status. Step 1: SELECT * FROM eav_attribute where entity_type_id = 4 AND attribute_code = 'status'; Step 2 UPDATE catalog_product_entity_int a, catalog_product_entity b SET a.value = "2" WHERE b.row_id = a.row_id AND b.sku ...


0

UPDATE catalog_product_entity_decimal val SET val.value = ROUND(val.value,2) WHERE val.attribute_id = ( SELECT attribute_id FROM eav_attribute eav WHERE eav.entity_type_id = 4 AND eav.attribute_code = 'price' ); and dont forget to reindex product prices from admin :)


0

I've got an extension that will get you 95% there https://github.com/DominicWatts/ClearAttribute/ This wipes values for supplied attribute code https://github.com/DominicWatts/ClearAttribute/blob/master/Console/Command/NullAttribute.php#L176 Instead of nulling value you want the mysql round function. So it should look something like this ['value' => new \...


1

When the allocated memory size for a temporary table will be greater than 20% of innodb_buffer_pool_size, the error message is written to the Magento log. Can you please update the value for batchRowsCount to 10000 in Vendor_Module/etc/di.xml file of catalog_category_product (Category Products) indexer. For more details related to Exceeding allocated memory ...


0

\ceil( round($value,2)); This will round up, meaning 1.555 is rounded up to 1.65 ! Let me know if you need any further assistance and don't forget to up vote and mark as answer if this solved your problem :)


1

In Magento Wishlist share code is Unique. When Customer was created at that time one row also created in wishlist Table and here stores Customer id in wishlist table has one Unique wishlist id and also have one Unique sharing code. If Login customer share wishlist then you have get login customer id and from this customer id you need to get sharing code ...


0

Make sure this php extension is enabled: extension=pdo_mysql


0

Rate Per Second = RPS Suggestions to consider for your RDS Parameters group innodb_flush_neighbors=2 # from 1 to reduce innodb_buffer_pool_pages_dirty of 38,718 faster innodb_lru_scan_depth=100 # from 1024 to conserve 90% of CPU cycles used for function read_rnd_buffer_size=64K # from 256K to reduce handler_read_rnd_next RPS of 104,614 read_buffer_size=...


0

To avoid data-type conversions, try this query, please SELECT SQL_NO_CACHE COUNT(DISTINCT e.entity_id) FROM catalog_product_entity AS e INNER JOIN catalog_category_product_index_store1 AS cat_index ON cat_index.product_id=e.entity_id AND cat_index.store_id=1 AND cat_index.category_id=10 INNER JOIN catalog_product_entity_int AS at_visibility_default ON (...


0

Did you get the solution for the same? I am also facing the same problem with Mageplaza blog extension.


1

DELETE FROM el_magento.catalog_product_entity_tier_price WHERE customer_Group_id = {your_customer_group_id}; This should solve your problem ;)


0

Try this Code <?php $date=date_create($dbh->Record['fulfillmentDate']); $fomated_date = date_format($date,"d/m/y"); echo $fomated_date; ?>


0

Assuming it's an EAV property, here is how you can get the value: SELECT * FROM el_magento.eav_attribute; -- get the attribute_id of your attribute Depending on the property type you just have to do a SELECT on one of the following tables: If you need further help feel free to ask and don't forget to up vote / mark as answer if this solved your issue ;)


1

This should work. $date_string = "2020-07-02 02:38:38"; // $dbh->Record['fulfillmentDate']; $fulfillment_date = date_create_from_format('Y-m-d H:i:s', $date_string); echo date("m.d.y", $fulfillment_date->getTimestamp()); Hope it will help. Thanks.


0

If you are doing this in order to have some sort of integration with a different system (for example an internal site /ERP) I strongly advise you not to work directly with Magento 2 database. You should use the REST Webservices Magento provides and store the information you need in MSSQL. In our case we created a C# library just for that purpose, to ...


0

Backup and replace Setup folder on the root with already installed magento 2.* setup folder. Then run the php bin/magento setup:upgrade and other.It will be fix.


0

I have created a module same as to import orders through csv. You can manually do by programatically order script.


Top 50 recent answers are included