News:

Looking for documentation? Take a look on our wiki

Main Menu

Set products as parent and not display child products in category view

Started by nmihos, October 25, 2013, 15:36:19 PM

Previous topic - Next topic

nmihos

Hello,

I have 2 questions. I use an ERP software and it has a connection with virtuemart 2. I set the products in my software and then i make a sychronization and i update my store. I have created my products with extra features size and color. But in database the products have created like this:
Shoe
Shoes Sport
Shoes Sport Black
Shoes Sport Black No 35
Shoes Sport Black No 36
.
.
.
.
Shoes Sport Black No 46

In my eshop i want to display in my category sport the product Shoes Sport Black and the products with size as child products. Two question:
1. How can i set existing product as parent to other existing products or set existing products as child to another existing product. I have created them via my software and i have already updated my database of virtuemart. I have found a way, updating the column parent_product_id in Table virtuemart_products manually (one by one). Is there a script or a faster way? 
2. I want to display only parent products to categories and not child products. Child products will be shown as a dropdown list in product detail page (i have created a custom field for that).

Sorry for my bad english.