Results 1 to 7 of 7
  1. #1
    Join Date
    May 2020
    Location
    Dallas, Texas
    Posts
    9
    Plugin Contributions
    0

    Default SQL Errors Post Checkout and Order Details

    Hi,
    I have just completed a long overdue upgrade from 1.3 to 1.5.7 c. Naturally there have been some teething issues. I am getting a couple of errors noted in the logs:

    i) On completing a payment (I use the paypal express checkout module) there is fatal SQL error in the logs:

    Unknown column 'language_code' in 'field list' :: INSERT INTO orders (customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, payment_module_code, shipping_method, shipping_module_code, coupon_code, cc_type, cc_owner, cc_number, cc_expires, date_purchased, orders_status, order_total, order_tax, currency, currency_value, ip_address, language_code, order_weight) VALUES ('1', 'rez khan', '', '306 starkweather drive', '', 'beaver dam', '53916', 'Wisconsin', 'United States', '2066966606', 'r1234######################', '2', 'John Smith', '', '1234 New Drive', '', 'New Town', '12345', 'TX', 'United States', '2', 'John Smith', '', 123 New drive', '', 'New Town', '12345', 'TX', 'United States', '2', 'Credit Card', 'paypaldp', 'Store Pickup (Walk In)', 'storepickup', '', 'Visa', 'John Smith, 'XXXXXX', '', now(), '2', '0.01055', '0.00055', 'USD', '1.000000', '99.91.162.121 - 99.91.162.121', 'en', '0') ==> (as called by)
    /home3/genesbea/public_html/genesweddingflorals/includes/functions/database.php

    ii) On clicking on the orders link in the admin area I get the following error which prevents orders from being displayed:

    Unknown column 'o.language_code' in 'field list' :: SELECT o.orders_id, o.customers_id, o.customers_name, o.payment_method, o.shipping_method, o.date_purchased, o.last_modified, o.currency, o.currency_value, s.orders_status_name, o.order_total, o.customers_company, o.customers_email_address, o.customers_street_address, o.delivery_company, o.delivery_name, o.delivery_street_address, o.billing_company, o.billing_name, o.billing_street_address, o.payment_module_code, o.shipping_module_code, o.orders_status, o.ip_address, o.language_code
    FROM (orders o )
    LEFT JOIN orders_status s ON (o.orders_status = s.orders_status_id AND s.language_id = 1) ORDER BY o.orders_id DESC ==> (as called by) /home3/genesbea/public_html/genesweddingflorals/GARDENIA/orders.php on line 1204 <== in /home3/genesbea/public_html/genesweddingflorals/includes/classes/db/mysql/query_factory.php on line 170.

    The URL of the shopping cart is https://genesweddingflorals.com/index.php.
    PHP version is 7.2
    Plugins : Zipship/Paypal Express

  2. #2
    Join Date
    Oct 2008
    Location
    Croatia
    Posts
    1,344
    Plugin Contributions
    15

    Default Re: SQL Errors Post Checkout and Order Details

    It seems you're missing a column in your orders table, specifically language_code. Did you run the zc_install to upgrade the database all the way to 1.5.7? What does your project_version database table say, is it showing 1.5.7c for both?
    Zen Cart Point of Sale? Sure: ZX POS - v2 released
    My site - Pro ZC Help | My portfolio | My plugins

  3. #3
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    7,844
    Plugin Contributions
    108

    Default Re: SQL Errors Post Checkout and Order Details

    This can happen if the ALTER TABLE statements for the orders table failed because there were misformatted dates in the orders table from plugins.

    https://docs.zen-cart.com/user/upgra...andardization/

    You can test this by going to phpMyAdmin and using performing the operation that was missed:

    ALTER TABLE orders ADD language_code char(2) NOT NULL default '';

    You will get an error message that tells you why this failed. Fix that error, then run the ALTER TABLE again.

    Then look at your upgrade logs and see what else was missed - you'll have to re-do those operations too.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.

  4. #4
    Join Date
    May 2020
    Location
    Dallas, Texas
    Posts
    9
    Plugin Contributions
    0

    Default Re: SQL Errors Post Checkout and Order Details

    Thanks!

  5. #5
    Join Date
    May 2020
    Location
    Dallas, Texas
    Posts
    9
    Plugin Contributions
    0

    Default Re: SQL Errors Post Checkout and Order Details

    Yep, ran the zc_install so I am up to date.

  6. #6
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    7,844
    Plugin Contributions
    108

    Default Re: SQL Errors Post Checkout and Order Details

    Bear in mind that just because the Version tab says database 1.5.7 doesn't mean the database was in fact successfully updated, especially in your case where it's known that you ran into errors. You have to look at the logs (if any) that were created during the update. If you have deleted those logs but you haven't gone live yet, re-load your old database and re-run zc_install.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.

  7. #7
    Join Date
    May 2020
    Location
    Dallas, Texas
    Posts
    9
    Plugin Contributions
    0

    Default Re: SQL Errors Post Checkout and Order Details

    It's looking good now. Thanks for your help!

 

 

Similar Threads

  1. SQL Query for extracting Order & Customer Details?
    By Rony in forum Managing Customers and Orders
    Replies: 7
    Last Post: 23 Sep 2010, 10:47 PM
  2. Where the order details are subbmited in SQL?
    By nidkolio in forum General Questions
    Replies: 9
    Last Post: 28 Aug 2009, 10:41 PM
  3. HELP.... Canada Post Errors installing SQL changes!!!
    By dpet102 in forum Addon Payment Modules
    Replies: 1
    Last Post: 27 Jun 2009, 11:57 PM
  4. Errors on paypal orders, and details not on receipt
    By shelley_w in forum Managing Customers and Orders
    Replies: 12
    Last Post: 14 Mar 2008, 03:25 AM
  5. Site SQL errors after sending email and order confirm
    By chief_wiggum in forum General Questions
    Replies: 1
    Last Post: 28 Aug 2006, 10:53 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR