[Skip to main content](#vessel-content)

#   Import assumes unique category

##

- **[csymmonds](/forum/user/9149-csymmonds "View csymmonds's Profile")**
- [![csymmonds's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/9149-csymmonds "View csymmonds's Profile") Topic Author
- [ Offline](/forum/user/9149-csymmonds)

Less More

- Posts: 113
- Thank you received: 18
-
-

13 years 11 months ago -  13 years 11 months ago [\#80999](#80999) by [csymmonds](/forum/user/9149-csymmonds "View csymmonds's Profile")  *[Import assumes unique category](/forum/3-bug-report/76551-import-assumes-unique-category#80999 "It appears that the import (and export) assumes that all category names throughout the hierarchy are unique. For product sites, this assumption seems too limiting, and in my view...flawed.  For example, we group products by their type into categories for presentation on the front-end. One product type we offer is &quot;Flags&quot;, another is &quot;Windless Flags&quot;. The intended use, cost and prospective customers are unique, so this type of grouping is needed.  Within each of these categories are child categories for the applicable industries as shown below:  Flags -&gt; Automotive Repair -&gt; Car Sales -&gt; Food Service  Windless Flags -&gt; Automotive Repair -&gt; Car Sales -&gt; Food Service  The export does not create a fully-qualified path in the hierarchy. For example, the categories column exported might contain &quot;Car Sales&quot;, which could apply to either parent, &quot;Flags&quot; or &quot;Windless Flags&quot;.  When I assign categories, export, then import, all flags that were in &quot;Windless Flags &#92; Car Sales&quot; are moved to &quot;Flags &#92; Car Sales&quot;.  To the point, it would seem that the export and import should reference a fully-qualified category, rather than assume that all children within the category hierarchy are unique.")* was created by *[csymmonds](/forum/user/9149-csymmonds "View csymmonds's Profile")*

It appears that the import (and export) assumes that all category names throughout the hierarchy are unique.
For product sites, this assumption seems too limiting, and in my view...flawed.

For example, we group products by their type into categories for presentation on the front-end.
One product type we offer is "Flags", another is "Windless Flags". The intended use, cost and prospective customers are unique, so this type of grouping is needed.

Within each of these categories are child categories for the applicable industries as shown below:

Flags
-&gt; Automotive Repair
-&gt; Car Sales
-&gt; Food Service

Windless Flags
-&gt; Automotive Repair
-&gt; Car Sales
-&gt; Food Service

The export does not create a fully-qualified path in the hierarchy. For example, the categories column exported might contain "Car Sales", which could apply to either parent, "Flags" or "Windless Flags".

When I assign categories, export, then import, all flags that were in "Windless Flags \ Car Sales" are moved to "Flags \ Car Sales".

To the point, it would seem that the export and import should reference a fully-qualified category, rather than assume that all children within the category hierarchy are unique.

Last edit: 13 years 11 months ago by [csymmonds](/forum/user/9149-csymmonds "View csymmonds's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC83NjU1MS1pbXBvcnQtYXNzdW1lcy11bmlxdWUtY2F0ZWdvcnk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86555
- Thank you received: 14304
-
-

13 years 11 months ago [\#81308](#81308) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Import assumes unique category](/forum/3-bug-report/76551-import-assumes-unique-category#81308 "It appears that the import (and export) assumes that all category names throughout the hierarchy are unique. For product sites, this assumption seems too limiting, and in my view...flawed.  For example, we group products by their type into categories for presentation on the front-end. One product type we offer is &quot;Flags&quot;, another is &quot;Windless Flags&quot;. The intended use, cost and prospective customers are unique, so this type of grouping is needed.  Within each of these categories are child categories for the applicable industries as shown below:  Flags -&gt; Automotive Repair -&gt; Car Sales -&gt; Food Service  Windless Flags -&gt; Automotive Repair -&gt; Car Sales -&gt; Food Service  The export does not create a fully-qualified path in the hierarchy. For example, the categories column exported might contain &quot;Car Sales&quot;, which could apply to either parent, &quot;Flags&quot; or &quot;Windless Flags&quot;.  When I assign categories, export, then import, all flags that were in &quot;Windless Flags &#92; Car Sales&quot; are moved to &quot;Flags &#92; Car Sales&quot;.  To the point, it would seem that the export and import should reference a fully-qualified category, rather than assume that all children within the category hierarchy are unique.")*

In the import, you can specify both a categories column, where you can specify the name of the category and the parent_category where you can specify the name of the parent category. That way, you can avoid the case where you have twice the same child category in two different categories.
Of course, instead of the category name, you can also specify in the categories field the namekey of the category (which is unique for each category) or the id of the category (which is of course also unique) and thus avoid any mistake with the import.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC83NjU1MS1pbXBvcnQtYXNzdW1lcy11bmlxdWUtY2F0ZWdvcnk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[csymmonds](/forum/user/9149-csymmonds "View csymmonds's Profile")**
- [![csymmonds's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/9149-csymmonds "View csymmonds's Profile") Topic Author
- [ Offline](/forum/user/9149-csymmonds)

Less More

- Posts: 113
- Thank you received: 18
-
-

13 years 11 months ago [\#81312](#81312) by [csymmonds](/forum/user/9149-csymmonds "View csymmonds's Profile")  Replied by *[csymmonds](/forum/user/9149-csymmonds "View csymmonds's Profile")* on topic *[Import assumes unique category](/forum/3-bug-report/76551-import-assumes-unique-category#81312 "It appears that the import (and export) assumes that all category names throughout the hierarchy are unique. For product sites, this assumption seems too limiting, and in my view...flawed.  For example, we group products by their type into categories for presentation on the front-end. One product type we offer is &quot;Flags&quot;, another is &quot;Windless Flags&quot;. The intended use, cost and prospective customers are unique, so this type of grouping is needed.  Within each of these categories are child categories for the applicable industries as shown below:  Flags -&gt; Automotive Repair -&gt; Car Sales -&gt; Food Service  Windless Flags -&gt; Automotive Repair -&gt; Car Sales -&gt; Food Service  The export does not create a fully-qualified path in the hierarchy. For example, the categories column exported might contain &quot;Car Sales&quot;, which could apply to either parent, &quot;Flags&quot; or &quot;Windless Flags&quot;.  When I assign categories, export, then import, all flags that were in &quot;Windless Flags &#92; Car Sales&quot; are moved to &quot;Flags &#92; Car Sales&quot;.  To the point, it would seem that the export and import should reference a fully-qualified category, rather than assume that all children within the category hierarchy are unique.")*

Thanks Nicolas.
The namekey sounds like the best approach since the parent category name could potentially exist elsewhere in a category hierarchy.

The parent_category for products isn't being exported.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC83NjU1MS1pbXBvcnQtYXNzdW1lcy11bmlxdWUtY2F0ZWdvcnk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.045 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
