Please help us to make AbanteCart Ideal Open Source Ecommerce Solution for everyone.

Support AbanteCart eCommerce

Author Topic: Import Wizard with Sub Category  (Read 142 times)

Offline ashtonm

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Import Wizard with Sub Category
« on: September 20, 2020, 07:40:46 PM »
I am having a problem with importing products into the right 'Sub Category'

for Example:
I have a Parent Category we'll call it 'Torches' and 'Torches has a 'Sub Category' called 'Night & Day'. These have already got products in.

I'm now trying to import products E.g. 'Super Torch' and that needs to be in 'Sub Category' Night & Day'.

It imports the product but creates a new 'Parent Category' called 'Night & Day'

The only way around this as I can find is buy calling the 'Sub Category' 'Night & Day' as SQL does not like just the '&' on it's own.

Other Imports allow this single '&' but not as described above.

Anyone know a way of fixing this in the code?

This must be a bug so needs looking into.

Thanks, and love using the cart.

Mike

Offline Basara

  • Administrator
  • Hero Member
  • *****
  • Posts: 4662
  • Karma: +241/-2
    • View Profile
Re: Import Wizard with Sub Category
« Reply #1 on: September 21, 2020, 01:08:03 AM »
Hello.

In CSV file for ptoduct set the full path to category like Torches, Night & Day
In the Improt wizard make sure to fill the "Split data by" field with comma
https://abantecart.atlassian.net/wiki/spaces/AD/pages/16777227/Import+Wizard

Offline ashtonm

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Re: Import Wizard with Sub Category
« Reply #2 on: September 24, 2020, 08:05:15 PM »
I did this also.

The bug is in the php for writing a sql update, alter or create statement.

It should read UPDATE table set category.name = 'Night & Day'

It is the same for "/ ' :"  etc...

I have done a search and replace in the csv to change '&' to '&' before import.

You don't need to do this on creation of sub categories. I creates without an issue.

Hope this makes sense and can be put right in future releases.

Cheers

 

Powered by SMFPacks Social Login Mod