cancel
Showing results for 
Search instead for 
Did you mean: 

Magento Coupon codes although deleted already, doesn't allow to create coupon with same code again

SOLVED

Magento Coupon codes although deleted already, doesn't allow to create coupon with same code again

1

I am not sure if it's some kind of core-logic(unknown to me) or a bug maybe, but even though I have already deleted a coupon-code rule from "Shopping Cart Price Rules", when I search in the "salesrule_coupon" table the deleted coupon code, it still shows up.

What happens due to the above scenario is that if I try to recreate the coupon-rule with same code, it doesn't allow me to do so and shows below message:

 

 

Coupon with the same code already exists.
2 ACCEPTED SOLUTIONS

Accepted Solutions

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

No, you need ssh for the this

View solution in original post

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

Hi @5d56814044f5f ,

 

Try to delete coupon code from table if exist, "salesrule_coupon".  Also, Enable the sql log using CLI command. When delete Or create coupon code from Magento admin panel to identify table issue.

 

sudo php bin/magento dev:query-log:enable

 

Thanks,

Mohammad Ahmad

View solution in original post

7 REPLIES 7

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

Hello, Please check the database table "salesrule_coupon" if the code entry is already in it, delete it and create the cart rule again. If the entry is not there and still you are facing the same issue, please check the link http://ka.lpe.sh/2014/10/07/magento-code-already-exists-fix/ Hope this will work for you. If it helps you, please give us kudos and accept it as solution. Thank you.

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

Is i possible from admin panel

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

Is it possible from admin panel

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

No, you need ssh for the this

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

Hi @5d56814044f5f,

Try reindexing and flush cache as well.

php bin/magento indexer:reindex
php bin/magento cache:flush

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

I tried this step, but it doesn't work
our developer team remove this code from the database

Re: Magento Coupon codes although deleted already, doesn't allow to create coupon with same code aga

Hi @5d56814044f5f ,

 

Try to delete coupon code from table if exist, "salesrule_coupon".  Also, Enable the sql log using CLI command. When delete Or create coupon code from Magento admin panel to identify table issue.

 

sudo php bin/magento dev:query-log:enable

 

Thanks,

Mohammad Ahmad