Mass delete products

  • Posts: 81481
  • Thank you received: 13062
  • MODERATOR
9 years 5 months ago #176965

Hi,

We tried with several FTP clients and it didn't work:
take.ms/TFiHn
If you can install a file manager extension on your website we could do it with a backend access.
extensions.joomla.org/extensions/core-en...ents/file-management

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177024

Hello,

Yes, during the weekend there was a snow storm - broken fibers.

I installed eXtplorer - seems to work just fine. Please try.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177213

Guys, any news?

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177381

It's been 2 days. Any kind of news or developments? Any attempts at fixing my issue? Please, some kind of reply..

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177451

Hi,

Sorry, I am currently on holidays and I don't had time until now.
As I have developed this part, I am in charge of that.

I will try to find the source of the issue and correct that thanks to the access provided.
I keep you informed.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177454

Ok. Thank you.

Be aware, there are down-times on my server, maybe once a day or once every 2 days, but they are very short, in case you try to connect and it doesn't work, please try again a little later - it will work.

Thank you and waiting news from you.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177461

Hi,

Problem solved, you now have access to the mass actions.

I just removed the following actions for the products in the hikashopmassaction plugin php file:
- Add a product
- Update related
- Update options
- Update characteristics

These actions are not very optimized and do some MySQL request too heavy when there is a lot of products in the database.
I will look how to improve that for a future release of HikaShop.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177489

Ok, thank you.

I will give it a try as per previous instructions - I will come back and tell you what happened.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177607

Hello,

Indeed, now the speed is not an issue - everything works fast.

I created a new mass action and you can see the settings - printscreen.



Also you can see the result in the error.png attachement.




I changed the mass action filter to not delete but to show the results. It gives the same error but it also gives me a table below. I attached for this display-products.png


in this image you can see how the app shows the product_parent_id - as a long string, not just the codes in blue above (which are in my csv).

I created another mass-action, to check the correct product_parent_id. You can see the filter attached: export-products.png



This created the csv attached: export.csv

File Attachment:

File Name: export.csv
File Size:20 KB


In this export you will see that product_parent_id is the same as in my filter csv - the format ABS00024 for example. Not as it appears in display-products.png

Please help me sort this out - it is really getting on my nerves, it should be something easy to do and I just can't get passed it. I left the actions there, the one set up to delete the products is named ID-to-delete.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177736

Hi,

Please uncheck the option "Save the products on Mass Action CSV import".
This option allow to add the products in your shop, but in your case the products are already in, and needs to be deleted.

Having the full name in display-products.png is normal, to be more understandable we display the product full name, but we check only it's code.

If unchecking the option is not enough, please tell me and on Monday I will go back on your extplorer in order to debug that.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177737

There's no difference upon checking or unchecking that option. The error is the same.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177912

Hi,

I just wanted to debug your mass action, but I have timeout when reaching your server.
Are there snow storms again ?

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177916

I'm sorry. It's ok now. Port 80 was being blocked.

It's ok now.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177920

That should be ok now, there was a missing line in the delete products mass action function.
Please keep me informed if it's ok in order to correct the code on our end too.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177932

It doesn't work.

But please - i mentioned - the action is already there, it is called IDs-to-delete. Just click it and click Process. You can see yourself if it works or not. I mean I know everytime I write here I get to the back of the line of people waiting for answers.

The error is the same - no difference.

Also, if you want to import the csv again yourself, as mentioned before , you can find the csv file at ip/ID-TO-DELETE.csv - the ip being the IP you're using to access the website.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177941

I just checked your csv file and it's indeed not correct, the first column must contain the column name so in your case "product_code" as you are managing product codes in the csv file.

If it still doesn't work so you will have to use the column name "product_id" and use the ids instead of the product codes.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177945

"product_parent_id"
"ABS00005"
"ABS00006"
"ABS00007"

This is how my csv starts now. And it's not product code it's product_parent_id.

I exported using mass action and it is exactly the same as my imported file now.

Are you sure all settings are correct in the mass action? Because the error is all mentioning "could not be imported Product not found".

I mean if it doesn't work - it means it's a bug. Using product_id instead of my field is not a solution is a workaround.

I have almost 150.000 products, each has multiple variants, total is aroudn 3.2 million variants. each variant has a product_id - that means 3.2 million product ids. I will simply not be able to delete a few hundred thousand ids from 3.2 million ids. The mysql will crash, the server will crash and hikashop will crash.

I had to split the import of products in almost 100 sepparate csv's to be able to do it without crashing and at each import i had to wait almost 40 minutes. When I tried to do this on a hosting service they kicked me out and closed my account because of the resources I was consuming. Now it's a quad-core i7 with 8 gigs of ram and a 15.000 scsi just for this website and still it barely works. So please don't tell me "use product ids if product_parent_id" doesn't work. It's not possible.

So i need the mass action to work.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177955

In HikaShop, when using the delete function in the product class you just have to delete the main product and the variants will be deleted too.

So setting "product_code" as column title should do the trick, it will delete the main product and its variants.
"ABS00005", etc are not ids but codes.

Please Log in or Create an account to join the conversation.

  • Posts: 90
  • Thank you received: 2
9 years 5 months ago #177965

I set in the file the first line to "product_code".
I selected in the mass action, first filter Product Columns - product_code = csv (the new csv, the one with "product_code" in the first line).

Same error.

I selected in the mass action, first filter Product Columns - product_parent_id = csv (the new csv, the one with "product_code" in the first line).

Same error.

I tried different settings besides "=", Begins width, Ends with, etc. wihtout click on process but to see how many "results" it says. No matter what you choose it says 2868086 results.

This is a product parent id: ABS00005. Try to delete it using mass action :). I think it would be easier and a lot faster for you to try directly than for me.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 5 months ago #177995

I have done some tests and the issue seems to be coming from the massaction class, a function is not handling a specific case.

So tomorrow morning I will debug that class on your website directly.
Can I set the error reporting level to "maximum" while debugging ?

Please Log in or Create an account to join the conversation.

Time to create page: 0.134 seconds
Powered by Kunena Forum