• Resolved Zade

    (@nothin7)


    Here’s a puzzle: I have a CSV that was exported using Woocommerce’s native export functionality. It has 34,647 rows: 34,646 product rows and a header row. I changed the title of the first and last product in this CSV, cleaned it up so it only has two columns, and exported a new CSV (UTF-8 encoding). It’s 1.4 MB. I then go to Products > Import, choose the file, check “Update existing products”, and Continue. On the next page, the ID and Name are mapped appropriately. I click Run the importer, and the import runs for about 20 minutes, then says “Import complete! 34,500 products updated”. Sure enough, the first product title has been updated, but the last product title has not. What happened to the last 146 products? I tried a CSV with just the last 147 products, in case there was some hiccup with product 34,501, but this CSV updated the last product title just fine. Is there some hard cap at 34,500? I changed max_execution_time and max_input_time to 0 (unlimited), max_input_vars to 4000, and memory_limit to 1024MB on my dedicated server, running PHP7 DSO mod_ruid2. I’ve tried this many times, same result: exactly 34,500 products updated. Running the latest version of Woocommerce (3.2.6). My caching plugin (W3TC) isn’t active, though I am using Cloudflare. Ideas? Anything else I can try?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter Zade

    (@nothin7)

    Update: After removing thousands of duplicate titles from the CSV, 25,185 product rows remained. When I upload this new data set (as a fresh import or to update existing products), only 25,080 of 25,185 products are imported, though again, the process says “Import complete!” I thought maybe there were some funky characters throwing things off, so I tried running the CSV through Plain Clip, which removes formatting and invisible characters and performs Unicode normalization. I even converted to ASCII and removed trailing, leading, and consecutive spaces. Still, no luck. Any suggestions of things to try would be most appreciated.

    What’s interesting is that in both cases, 99.58% of products are updated:
    25080/25185 = 0.99583
    34500/34646 = 0.99578

    • This reply was modified 6 years, 3 months ago by Zade.
    Thread Starter Zade

    (@nothin7)

    I’m pretty sure this is endemic to WooCommerce’s native import functionality, for the following three reasons:

    1) A simple CSV with 34,646 rows of “Great book” at $5, no other columns besides Name and Price, “completes” at 34,500.

    2) I tried importing my clean CSV of 25,185 products on an entirely new server, different web host, brand new WordPress installation using the default theme (Twenty Seventeen) and Woocommerce as the only active plugin, and again it “completes” at 25,080.

    3) As mentioned in my previous reply, in all cases, 99.58% of products are updated.

    For anyone else reading this and looking for an interim solution, I had success with WP All Import and their WooCommerce add-on: https://wordpress.org/plugins/woocommerce-xml-csv-product-import/. No, I am not affiliated with this company. I really hope WooCommerce will address this bug because I find the native import tools much cleaner and simpler.

    Thread Starter Zade

    (@nothin7)

    Aha! I discovered a workaround. Simply add thousands of rows of empty data. So, here is what my CSV looks like…

    Line 1: ID,Name,Stock,Regular price,Categories,Meta: shelve date,Meta: author,Meta: format

    Line 2: 18,Adventures,1,,MYS,6/5/2016,”Queen, Ellery”,PB
    .
    .
    .
    Line 25,186: 25203,Zunis: Self Portrayals,1,,NVAM,10/19/2014,Zuni People,QPB

    Lines 25,187-27,000: ,,,,,,,

    The result? “Import complete! 25,185 products updated”. The best part? Those 1814 lines of empty data don’t add blank products. This will do.

    Plugin Support Hannah S.L.

    (@fernashes)

    Automattic Happiness Engineer

    Thanks for letting us know what you worked out!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Import “succeeds” at 34,500 products, missing 164’ is closed to new replies.