Title: Error while saving products
Last modified: March 17, 2020

---

# Error while saving products

 *  Resolved [Dimoteca](https://wordpress.org/support/users/albertsauque/)
 * (@albertsauque)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/error-while-saving-products/)
 * I am trying to update the stocks, and when I hit on saving I get an error:
    Error
   while saving products
 * Why is this happening?
 * Thanks

Viewing 7 replies - 1 through 7 (of 7 total)

 *  Plugin Author [pimwick](https://wordpress.org/support/users/pimwick/)
 * (@pimwick)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12553288)
 * It sounds like the server is timing out before it finishes saving the batch. 
   Instead of saving all records at the same time, we batch them into 25 so that
   servers can finish processing them before moving on to the next batch.
 * On some hosts, 25 is still too high and the batches need to be smaller so they
   can complete successfully before the web browser gives up and stops waiting (
   throwing an error).
 * To adjust the batch size perform the following steps:
 * 1. Log into your FTP site and edit wp-config.php
    2. Edit wp-config.php and scroll
   to the end and add the following bit of code:
 * Scroll towards the bottom, and before the line that says “Happy blogging.” add
   this code ABOVE that line (translate as needed):
 *     ```
       define( 'PWBE_SAVE_BATCH_SIZE', 5 );
   
       /* That's all, stop editing! Happy blogging. */
       ```
   
 * 3. Save the wp-config.php file and re-upload it to your server.
 * Adjust the value until you find the sweet spot where it doesn’t timeout. A batch
   size of 1 will save each field one after the other.
 * If you have any questions just let me know!
 *  [ahipgrave](https://wordpress.org/support/users/ahipgrave/)
 * (@ahipgrave)
 * [6 years, 1 month ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12620342)
 * Hi
 * I’m having the same problem. I have tried adding the code with the value of 5.
   Still can’t save anything after editing. I then tried a value of 1 – no difference.
   Not sure if there’s been an update of woo recently that has caused this.
 * Regards
 * Anthony
 *  Plugin Author [pimwick](https://wordpress.org/support/users/pimwick/)
 * (@pimwick)
 * [6 years, 1 month ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12620375)
 * Check the PHP error log and see if there are any clues as to what is stopping
   the process from saving.
 * Perform the following steps please:
 * 1. Log into your FTP site and edit wp-config.php
    2. Set the following values(
   add the lines if they don’t exist):
 *     ```
           define( 'WP_DEBUG', true );
           define( 'WP_DEBUG_LOG', true );
           define( 'WP_DEBUG_DISPLAY', false );
           @ini_set( 'display_errors', 0 );
       ```
   
 * 3. Return to the site and trigger the error again by trying to save.
    4. Now 
   go back to FTP and look at the file /wp-content/debug.log 5. Return to wp-config.
   php and set DEBUG back to false (reverting the changes made in Step 2)
 * Let me know if you have any questions!
 *  [ahipgrave](https://wordpress.org/support/users/ahipgrave/)
 * (@ahipgrave)
 * [6 years, 1 month ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12620385)
 * All seems to be working OK now! Not exactly sure why.
 *  [ahipgrave](https://wordpress.org/support/users/ahipgrave/)
 * (@ahipgrave)
 * [6 years, 1 month ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12620390)
 * Just saw your reply after I had posted this as now working. Will try those steps
   if I have any further problems.
 * For anyone thinking about this plugin, I recommend you give it a try as it is
   extremely useful and the support is great!
 *  [ahipgrave](https://wordpress.org/support/users/ahipgrave/)
 * (@ahipgrave)
 * [6 years, 1 month ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12620410)
 * Seems to have been related to not updating WP from 4.0.0 to 4.0.1 and making 
   sure that a refresh has happened on the PW Bulk Edit page before testing again.
 *  Plugin Author [pimwick](https://wordpress.org/support/users/pimwick/)
 * (@pimwick)
 * [6 years, 1 month ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12620532)
 * Thanks for following up, glad to hear you got it sorted out. Best of luck with
   your store!

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Error while saving products’ is closed to new replies.

 * ![](https://ps.w.org/pw-bulk-edit/assets/icon-256x256.png?rev=1493564)
 * [PW WooCommerce Bulk Edit](https://wordpress.org/plugins/pw-bulk-edit/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/pw-bulk-edit/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/pw-bulk-edit/)
 * [Active Topics](https://wordpress.org/support/plugin/pw-bulk-edit/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/pw-bulk-edit/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/pw-bulk-edit/reviews/)

 * 7 replies
 * 3 participants
 * Last reply from: [pimwick](https://wordpress.org/support/users/pimwick/)
 * Last activity: [6 years, 1 month ago](https://wordpress.org/support/topic/error-while-saving-products/#post-12620532)
 * Status: resolved