Unable to save Product Type settings of an Item / Product

Started by robert101083, December 02, 2010, 08:19:55 AM

Previous topic - Next topic

robert101083

Hi,

I created a Product Type called "Schoenen" and added it to a Item / Product. When I select the new tab created for the Product Type when updating an Item I get an error when I save the setting (Also see attached files).

Error:
JDatabaseMySQL::query: 1054 - Unknown column 'shoe_size' in 'field list' SQL=UPDATE jos_vm_product_type_1 SET product_id='1',`shoe_size`='36;37;38;39',`shoe_color`='Purple',`shoe_studs_cleats`='AG (Artificial Grass)' WHERE product_id = 1

What's wrong here. Is this a bug in VM 1.1.6?

Cheers,
Robert

[attachment cleanup by admin]

franzpeter

There seems to be a problem with the product type id in the database. You define a product type: size and another one with color. Both should have different product_type_id. If you create a product type: color the database creates an entry like product type id: 1
product type name: color
If you create a product type size, the database should create something like:
product type id: 2
product type name: color
a.s.o..

robert101083

Quote from: franzpeter on December 02, 2010, 12:23:53 PM
There seems to be a problem with the product type id in the database. You define a product type: size and another one with color. Both should have different product_type_id. If you create a product type: color the database creates an entry like product type id: 1
product type name: color
If you create a product type size, the database should create something like:
product type id: 2
product type name: color
a.s.o..

Update_Item_Test_3.png is a print screen of jos_vm_product_type_parameter. I attached an extra picture to the OP with the jos_vm_product_type table. I do not think that's the problem.

robert101083

I had a better look at the error:

Unknown column 'shoe_size' in 'field list' SQL=UPDATE jos_vm_product_type_1. Then I found out that jos_vm_product_type_1indeed was missing "shoe_size". I removed "shoe_size" as Product Type Parameter in Virtuemart an created a new one and added it again to the product. Problem solved.

The reason why it gone wrong is, I THINK, because of the "Parameter Type" of "shoe_size" was changed (Short Text to Multiple Values) after I added the Product Type to the product.