awocoupon free version 2.0.17 SQL Error on primary key with VM3!

  • Default avatar
     2 years ago


    Settings awocoupon: no limit on use, 25 euro discount on all orders
    Using the free version works fine with the first use of the coupon code.
    The second use of the coupon code gives a SQL error:
    Duplicate entry '1-0' for key 'PRIMARY' SQL=INSERT INTO zlto4_awocoupon_vm_history (coupon_id,user_id,num) VALUES (1,0,1)

    The reason for this is I think that in our case the user_id is always 0 (zero) because we us quest account checkout.
    Therefore the PRIMARY KEY (`coupon_id`,`user_id`) is invalid.

    Workaround is removing the primary key for now!