News:

Looking for documentation? Take a look on our wiki

Main Menu

Error in Deleting new orders after migrate

Started by Daniel Sjöstrand, March 16, 2015, 00:27:38 AM

Previous topic - Next topic

Daniel Sjöstrand

I have a problem deleting new orders after upgrade.
I get this error message

vmError: TableInvoices COM_VIRTUEMART_INVOICE_NUMBER in record is missing! Can't save the record with no COM_VIRTUEMART_INVOICE_NUMBER

Looking in the database I see that deleting an order does not delete latest input into table "virtuemart_invoices"

The invoice is created correctly and sent through email.
I can delete old orders without error.

I also see an unconsistancy in the virtuemart_invoice_id table, a jump from 681,682,693,694 etc.
The orders after the jump is new test orders only. Tried the "repair table" i phpmyadmin - but it still jumps in the sequence
  - I actually solved this using - Repair table in phpmyadmin and then changed the AUTO_INCREMENT to correct value - but still the same error.

So please any hint on how to correct this database and probably remove the error would be really appreciated

VirtueMart 3.0.6.2 (upgrade from 2.0.24c)
Joomla 3.4 (upgrader from Joomla! 2.5.8)

Daniel Sjöstrand

Fixed the miss match on table invoices autoincrease with phpmyadmin

Only thing not working is when deleting orders the invoice is not renamed as it should.
Instead of solving this i decided to add a new order status and not delete the faulty orders.


apri

#2
I think it's a bug in virtuemart, I've attached mysql log, which was generated upon clicking on delete order. by the end of the fragment, last statement before generating error was delete from jos_virtuemart_orders, and then an error message into user session, so I think the code was looking for the some info from the virtuemart_orders, but that record was gone




Milbo

Apri, I answered you already here http://forum.virtuemart.net/index.php?topic=129123.0
which should be also the solution for
Quote from: Daniel Sjöstrand on March 18, 2015, 12:15:10 PM
Only thing not working is when deleting orders the invoice is not renamed as it should.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/