Forums / Upgrading from 1.3.x to 1.3.9 / Coupons no longer working.

Coupons no longer working.

Locked

Started by peter_homann on 8 Feb 2007, 12:16 AM · Views: 4,823

Results 1 to 19 of 19
This thread is locked. New replies are disabled.
8 Feb 2007, 12:16 AM
#1
peter_homann avatar

peter_homann

Zen Follower

Join Date:
Jun 2006
Location:
Melbourne, VIC
Posts:
106
Plugin Contributions:
0

Coupons no longer working.

Hi,

I upgraded from 1.3.5 to 1.3.7 last week. I thought everyting was fine, But, when I went to Admin-> Coupon Admin, none of my coupons were displayed. :cry:

Instead the following error was displayed above the heading.

1054 Unknown column 'coupon_zone_restriction' in 'field list'
in:
[select coupon_id, coupon_code, coupon_amount, coupon_type, coupon_start_date,coupon_expire_date,uses_per_user,uses_per_coupon,restrict_to_products, restrict_to_categories, date_created,date_modified, coupon_active, coupon_zone_restriction from zen_coupons where coupon_active='Y' and coupon_type != 'G' limit 0, 20]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

Can anyone help out please.

Cheers,

Peter.

8 Feb 2007, 1:09 AM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

Sounds like you did not upgrade your database with the /zc_install

Did you Upgrade your database AFTER making a backup of it?

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Feb 2007, 1:33 AM
#3
peter_homann avatar

peter_homann

Zen Follower

Join Date:
Jun 2006
Location:
Melbourne, VIC
Posts:
106
Plugin Contributions:
0

Re: Coupons no longer working.

Ajeh:

Sounds like you did not upgrade your database with the /zc_install

Did you Upgrade your database AFTER making a backup of it?

Hi Linda,

Thanks for the reply. I did the upgrade via fantastico that creates a backup. After the upgrade, Zencart complained that the DB was at ver 1.3.6 so I uploaded ZC_install and ran that, only doing a db upgrade. Everything seemed to be OK after that.

I now realise that using Fantasticio is not required or the correct way to go.

Cheers,

Peter.

8 Feb 2007, 1:45 AM
#4
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

Thanks for the update and glad you have things back up and running ... :smile:

Fantastico is nice for a test run or a first install ... but after that it is best to manage things on your own with nice clean downloads via the Downloads link at the top of your screen ... :cool:

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Feb 2007, 2:39 AM
#5
peter_homann avatar

peter_homann

Zen Follower

Join Date:
Jun 2006
Location:
Melbourne, VIC
Posts:
106
Plugin Contributions:
0

Re: Coupons no longer working.

Ajeh:

Thanks for the update and glad you have things back up and running ... :smile:

Fantastico is nice for a test run or a first install ... but after that it is best to manage things on your own with nice clean downloads via the Downloads link at the top of your screen ... :cool:

Hi Linda,

No things are not OK.:cry:

I ran the ZC_Install after I did the Fantastico installation and I though all was well.

Today I discovered that the coupons are not working.

I had a look in the database by using phpMyAdmin, (I'm using cpanel) and the field 'coupon_zone_restriction' does not exist.

Is it possible to insert it into the database? Mind you I'm no database developer.

Also I looked in the Fantastico backup, no database. :(

Thanks

Peter.

8 Feb 2007, 2:42 AM
#6
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

Make sure you loaded all the files for Zen Cart v1.3.7 to your site ...

Backup your database ...

Re-run the Upgrade Database ...

See who is checked ... and run each 1 by 1 ...

Then ...

Check your Discount Coupons ...

If you have restrictions ... add the Restriction for:

Top Category Deny

This should get them running again ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Feb 2007, 2:57 AM
#7
peter_homann avatar

peter_homann

Zen Follower

Join Date:
Jun 2006
Location:
Melbourne, VIC
Posts:
106
Plugin Contributions:
0

Re: Coupons no longer working.

Ajeh:

Make sure you loaded all the files for Zen Cart v1.3.7 to your site ...

Backup your database ...

Re-run the Upgrade Database ...

See who is checked ... and run each 1 by 1 ...

Then ...

Check your Discount Coupons ...

If you have restrictions ... add the Restriction for:

Top Category Deny

This should get them running again ...

I re-ran the upgrade database, just to see what was checked, and none of the database upgrades a checked. It indicates that the database is at 1.3.7

Cheers,

Peter.

8 Feb 2007, 3:01 AM
#8
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

For giggles ... backup your database and run the Upgrade Database and check the checkbox for:
Upgrade DB from 1.3.6 to 1.3.7

You will recieve messages on things done but it should also fix the things not done ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Feb 2007, 3:14 AM
#9
peter_homann avatar

peter_homann

Zen Follower

Join Date:
Jun 2006
Location:
Melbourne, VIC
Posts:
106
Plugin Contributions:
0

Re: Coupons no longer working.

OK, did that but no joy...

Messages were;
at top of DB Upgrade page

12 statements processed.
Note: 7 statements ignored. See "upgrade_exceptions" table for additional details.

at bottom of DB Upgrade page

SKIPPED: Cannot insert configuration_key "USE_SPLIT_LOGIN_MODE" because it already exists
SKIPPED: Cannot ADD column customers_paypal_payerid because it already exists.
SKIPPED: Cannot ADD column customers_paypal_ec because it already exists.
SKIPPED: Cannot insert configuration_key "CC_ENABLED_SOLO" because it already exists
SKIPPED: Cannot insert configuration_key "CC_ENABLED_SWITCH" because it already exists
SKIPPED: Cannot insert configuration_key "CC_ENABLED_MAESTRO" because it already exists
SKIPPED: Cannot insert configuration_key "DEFINE_PAGE_NOT_FOUND_STATUS" because it already exists
SKIPPED: Cannot insert configuration_key "DEFINE_PAGE_NOT_FOUND_STATUS" because it already exists
SKIPPED: Cannot insert configuration_key "DEFINE_PAGE_NOT_FOUND_STATUS" because it already exists
SKIPPED: Cannot insert configuration_key "DEFINE_PAGE_NOT_FOUND_STATUS" because it already exists

Thanks,

Peter.

8 Feb 2007, 3:37 AM
#10
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

Are you sure you have the right database and prefix being used?

Look at your database in phpMyAdmin and make sure you are using the same database in both configure.php files:
/includes/configure.php
/admin/includes/configure.php

Same prefix, server, database, username, password, domain and paths ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Feb 2007, 5:06 AM
#11
peter_homann avatar

peter_homann

Zen Follower

Join Date:
Jun 2006
Location:
Melbourne, VIC
Posts:
106
Plugin Contributions:
0

Re: Coupons no longer working.

Linda,

I checked all the settings and all appeared OK. So I tried adding the coupon_zone_restriction field. I copied the field definition from a test database.

The end result is that it appears to work.

I'm a bit concerned and feel like I should backup what is there and try to load it into a fresh database. I'll have to wait until I'm bold enough.

thanks for all your help.

Peter.

5 Mar 2007, 1:18 AM
#12
usahog avatar

usahog

New Zenner

Join Date:
Jun 2006
Location:
Illinois
Posts:
27
Plugin Contributions:
0

Re: Coupons no longer working.

Peter Homann:

Linda,

I checked all the settings and all appeared OK. So I tried adding the coupon_zone_restriction field. I copied the field definition from a test database.

The end result is that it appears to work.

I'm a bit concerned and feel like I should backup what is there and try to load it into a fresh database. I'll have to wait until I'm bold enough.

thanks for all your help.

Peter.

I have the exact same problem and I have did all the steps in this topic except adding as Peter did above. Can someone please tell me where to add the coupon_zone_restriction field? Also, where can I get the field to add?

Thanks,
Russ

5 Mar 2007, 2:11 AM
#13
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

First ... backup your database and then run:

/zc_install

and click the Database Upgrade ...

Are any of the checkboxes checked?

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

5 Mar 2007, 2:15 AM
#14
usahog avatar

usahog

New Zenner

Join Date:
Jun 2006
Location:
Illinois
Posts:
27
Plugin Contributions:
0

Re: Coupons no longer working.

No boxes are checked and I ran the zc_install. I checked the 1.36 to 1.37 and did the database upgrade. It stated that nothing was done because all the files were already there?

Usahog

5 Mar 2007, 2:20 AM
#15
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

Having assured that you have the Database backed up ...

Check in phpMyAdmin the table for:
coupons

do you have the field:
coupon_zone_restriction

If not, if not using prefixes on your database, you can run these statements in your SQL area of phpMyAdmin ...

# Updating coupon-related tables
ALTER TABLE coupons ADD coupon_zone_restriction INT( 11 ) NOT NULL DEFAULT '0';
ALTER TABLE coupons CHANGE coupon_minimum_order coupon_minimum_order DECIMAL( 15, 4 ) NOT NULL DEFAULT '0.0000';
ALTER TABLE coupons CHANGE coupon_amount coupon_amount DECIMAL( 15, 4 ) NOT NULL DEFAULT '0.0000';
ALTER TABLE coupon_gv_customer CHANGE amount amount DECIMAL( 15, 4 ) NOT NULL DEFAULT '0.0000';
ALTER TABLE coupon_gv_queue CHANGE amount amount DECIMAL( 15, 4 ) NOT NULL DEFAULT '0.0000';

If you do have prefixes, you can run the above in the Tools ... Install SQL Patches ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

5 Mar 2007, 2:21 AM
#16
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

Also, from what version did you upgrade and how?

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

5 Mar 2007, 2:32 AM
#17
usahog avatar

usahog

New Zenner

Join Date:
Jun 2006
Location:
Illinois
Posts:
27
Plugin Contributions:
0

Re: Coupons no longer working.

Ajeh,

I ran the statements in the SQL and it fixed it.

Thank you so much.

Now for another question. I have another question. Were is my referrals?

When I place a test order it does not give me an option to use if I was referred by someone?

I have never had this on any of my Zencart versions, but I see different ones referring to it.

Thanks,

Hog

5 Mar 2007, 2:47 AM
#18
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coupons no longer working.

It would be helpful to keep questions on their own topics ... but since I am here ...

The Coupon Referral is set in the Configuration ... Customer Details ...

Customers Referral Status
Customers Referral Code is created from
0= Off
1= 1st Discount Coupon Code used
2= Customer can add during create account or edit if blank

NOTE: Once the Customers Referral Code has been set it can only be changed in the Admin Customer

When the referral is used, you can observe the sales made by customers in the Reports ... Customers Referral Report ...

Note: nothing will appear in the dropdown for:
Select a Referral/Coupon Code

until someone has claimed the coupon redeem code (referral code)

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

5 Mar 2007, 4:45 AM
#19
usahog avatar

usahog

New Zenner

Join Date:
Jun 2006
Location:
Illinois
Posts:
27
Plugin Contributions:
0

Re: Coupons no longer working.

Thank you very much for the information. You have been a great help!!

Hog :thumbsup: