VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: capewellmj on November 18, 2015, 16:59:54 PM

Title: Cannot update order information in backend
Post by: capewellmj on November 18, 2015, 16:59:54 PM
When we try to change any part of an order in the backend. To either the address details (order head) or change the product details we get this error.

1054 Unknown column 'order_create_invoice_pass' in 'field list' SQL=UPDATE `prefix_virtuemart_orders` SET `virtuemart_user_id`='0',`virtuemart_vendor_id`='1',`order_number`='1000',`order_pass`='p_c74ac',`order_create_invoice_pass`='0',`customer_number`='nonreg_test@g',`order_total`='145.19000',`order_salesPrice`='115.20000',`order_billTaxAmount`='0.00000',`order_billTax`='0',`order_billDiscountAmount`='0.00000',`order_discountAmount`='0.00000',`order_subtotal`='115.20000',`order_tax`='0.00000',`order_shipment`='29.99',`order_shipment_tax`='0.00000',`order_payment`='0.00',`order_payment_tax`='0.00000',`coupon_discount`='0.00',`order_discount`='0.00',`order_currency`='144',`order_status`='C',`user_currency_id`='144',`user_currency_rate`='1.00000',`virtuemart_paymentmethod_id`='1',`virtuemart_shipmentmethod_id`='33',`ip_address`='192.test',`order_language`='en-GB',`delivery_date`='Same as invoice date',`created_on`='2015-09-21 17:31:53',`modified_on`='2015-11-18 15:53:08',`modified_by`='100' WHERE `virtuemart_order_id`='1000'

Can somebody test this and offer a fix? We have to be able to update orders. I think it did this before for VM 3.0.9.4 but Milbo offered a fix.

Thanks,

Martin

VirtueMart 3.0.12
Joomla 3.4.5
Title: Re: Cannot update order information in backend
Post by: Milbo on November 19, 2015, 00:11:00 AM
use the tableupdater, it should add the missing field
Title: Re: Cannot update order information in backend
Post by: capewellmj on November 23, 2015, 20:11:55 PM
Hi Max

I just went to "install or if necessary update tables" and got this error.

1062 Duplicate entry 'USD' for key 'currency_code_3' SQL=ALTER TABLE `prefix_virtuemart_currencies` ADD UNIQUE KEY `currency_code_3` (`currency_code_3`)

It didn't update and I still cannot update orders.

Any ideas.

Martin
Title: Re: Cannot update order information in backend
Post by: Milbo on November 25, 2015, 10:31:29 AM
It should update the rest of your tables. Go in your currencies table and change the currency code 3.
Title: Re: Cannot update order information in backend
Post by: capewellmj on November 25, 2015, 14:36:00 PM
That worked. I had duplicate USD currencies.

Also I think I forgot to click "Enable database Update tools" in the configuration before using the table update.

Thanks for your help :)
Title: Re: Cannot update order information in backend
Post by: Milbo on November 25, 2015, 20:53:43 PM
The reason I added this UNIQUE. It prevents this in future and it was just luck that you didnt got problems with the doubled currency_3_code