Results 1 to 10 of 12

Thread: Unknown column 'p.products_id' in 'on clause'

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    jmarcv's Avatar
    jmarcv is offline Cranky Coder
    Join Date
    Jan 2005
    Posts
    354

    Default ZEN Cart fix

    Here is a similar fix for Zen Cart:

    The fix for OSCmax on 'index.php' listed above applies to

    includes/index_filters/default_filter.php

    for Zen cart and potentially other scripts as well. Zen cart uses OSCommerce code.
    Last edited by Matt; 09-25-2006 at 07:04 PM. Reason: clarification

  2. #2
    sergey is offline Master Glow Jedi
    Join Date
    Aug 2005
    Posts
    472

    Default Zen Cart

    if you find the fix above does not correct all issues, you need to replace the following sql query in the file includes/modules/meta_tags.php to fix your Zen Cart:

    $sql= "select pd.products_name, p.products_model, p.products_price_sorter, p.products_tax_class_id,
    p.metatags_title_status, p.metatags_products_name_status, p.metatags_model_status,
    p.products_id, p.metatags_price_status, p.metatags_title_tagline_status,
    pd.products_description,
    mtpd.metatags_title, mtpd.metatags_keywords, mtpd.metatags_description
    from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd left join " . TABLE_META_TAGS_PRODUCTS_DESCRIPTION . " mtpd on mtpd.products_id = p.products_id and mtpd.language_id = '" . (int)$_SESSION['languages_id'] . "'
    where p.products_id = '" . (int)$_GET['products_id'] . "'
    and p.products_id = pd.products_id
    and pd.language_id = '" . (int)$_SESSION['languages_id'] . "'";
    with:
    $sql= "select pd.products_name, p.products_model, p.products_price_sorter, p.products_tax_class_id,
    p.metatags_title_status, p.metatags_products_name_status, p.metatags_model_status,
    p.products_id, p.metatags_price_status, p.metatags_title_tagline_status,
    pd.products_description,
    mtpd.metatags_title, mtpd.metatags_keywords, mtpd.metatags_description
    from (" . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd) left join " . TABLE_META_TAGS_PRODUCTS_DESCRIPTION . " mtpd on mtpd.products_id = p.products_id and mtpd.language_id = '" . (int)$_SESSION['languages_id'] . "'
    where p.products_id = '" . (int)$_GET['products_id'] . "'
    and p.products_id = pd.products_id
    and pd.language_id = '" . (int)$_SESSION['languages_id'] . "'";
    Last edited by Matt; 09-26-2006 at 09:07 AM.

  3. #3
    olagod is offline Almost no longer a newbie!
    Join Date
    Jan 2008
    Posts
    3

    Thumbs up This worked perfectly for me!

    Quote Originally Posted by sergey View Post
    if you find the fix above does not correct all issues, you need to replace the following sql query in the file includes/modules/meta_tags.php to fix your Zen Cart:


    with:
    This was the fix to a completely unexpected and out-of-the-blue error and since I don't write PHP I was really in a pinch to get a customer's shopping cart working again. The fix you listed had me back in place within minutes and this would have been a real mess without your help. A million thanks for this!

  4. #4
    olagod is offline Almost no longer a newbie!
    Join Date
    Jan 2008
    Posts
    3

    Default

    Quote Originally Posted by olagod View Post
    This was the fix to a completely unexpected and out-of-the-blue error and since I don't write PHP I was really in a pinch to get a customer's shopping cart working again. The fix you listed had me back in place within minutes and this would have been a real mess without your help. A million thanks for this!
    OOPS! spoke too soon, now I am getting Fatal error: Call to a member function Execute() on a non-object in /home/xxxxx/public_html/store1/includes/functions/sessions.php on line 72

    well, off to figure out what to do about this one now...

LinkBacks (?)


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14