{"id":3229,"date":"2014-05-02T20:16:12","date_gmt":"2014-05-02T20:16:12","guid":{"rendered":"https:\/\/www.inmotionhosting.com\/support\/2014\/05\/02\/ups-module-misssing-products\/"},"modified":"2021-08-16T23:01:42","modified_gmt":"2021-08-17T03:01:42","slug":"ups-module-misssing-products","status":"publish","type":"post","link":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/","title":{"rendered":"Fix: Missing Products in UPS Module Settings for PrestaShop"},"content":{"rendered":"<div class=\"in_this_tutorial\">\n<h2>In this tutorial:<\/h2>\n<p><a class=\"btn btn-primary\" href=\"#what\" type=\"button\">What is the error?<\/a> <a class=\"btn btn-primary\" href=\"#cause\" type=\"button\">What causes it?<\/a> <a class=\"btn btn-primary\" href=\"#fix\" type=\"button\">How to fix it<\/a><\/p>\n<\/div>\n<p><a href=\"https:\/\/www.ups.com\" target=\"_blank\" rel=\"noopener noreferrer\">UPS<\/a> is one of the most recognized names in the shipping industry. They are also a very common choice when shipping products to your customers. PrestaShop has modules for UPS so that you can use them for your shipping needs. There seems to be an issue in the free UPS module (<em>upscarrier<\/em>, aka <em>Connect to UPS<\/em>) when configuring the module. The products are not always being listed in the <em>Product Settings<\/em> tab when configuring the modules. This article explains the issue and how to fix it for your PrestaShop store.<\/p>\n<div class=\"alert\"><span style=\"color: red;\"><span style=\"color: red;\"> <strong>NOTE:<\/strong><\/span><\/span>\n<ul>\n<li>The steps below are specifically presented for those with cPanel based webservers. As long as you can access your file structure, however, you can implement the actual fix.<\/li>\n<li>This fix works for both PrestaShop 1.5.x and 1.6.x versions.<\/li>\n<\/ul>\n<\/div>\n<p><a name=\"what\"><\/a><\/p>\n<h2>What is the exact error?<\/h2>\n<p><img decoding=\"async\" class=\"std_ss\" style=\"float: right; margin: 0px 15px 15px 15px;\" title=\"Click here to view the larger image\" src=\"\/support\/images\/stories\/edu\/ps16\/errors\/modules\/upscarrier\/missing-products\/before.png\" alt=\"\" width=\"200\">The drop-down menu in the <em>Product Settings<\/em> tab of the UPS module is supposed display products, but it is empty.<\/p>\n<div style=\"clear: both;\"><\/div>\n<p><a name=\"cause\"><\/a><\/p>\n<h2>What is causing the error?<\/h2>\n<p>The error is caused by an SQL <a href=\"https:\/\/dev.mysql.com\/doc\/refman\/5.7\/en\/select.html\" target=\"_blank\" rel=\"noopener noreferrer\"><em>SELECT<\/em> statement<\/a> where the products are supposed to be pulled from the database to populate the dropdown. It actually finds the number of products and sets as many blank rows, so the data is coming back as <a href=\"https:\/\/en.wikipedia.org\/wiki\/Null_%28SQL%29\" target=\"_blank\" rel=\"noopener noreferrer\">NULL<\/a>. When checking, we noticed that the limiting factor is the <em>id_lang<\/em> column setting. It is currently set to \u2018<em>2<\/em>\u2018.<\/p>\n<p>The test installation had only the default language of \u201c<em>English<\/em>\u201c. This is represented in the code by the variable \u201c<em>lang_id<\/em>\u201c. If only one language is loaded, then then \u201c<em>lang_id<\/em>\u201d would be equal to \u201c<em>1<\/em>\u201c. Replacing the hard set code of \u2018<em>2<\/em>\u2018 with the dynamic code <em>$this-&gt;context-&gt;language<\/em> allows the proper language id to be used. This allows the dropdown to populate with the products.<\/p>\n<p><a name=\"fix\"><\/a><\/p>\n<h2>How to fix the missing products in the UPS product settings<\/h2>\n<ol class=\"article_list\">\n<li><a href=\"https:\/\/www.inmotionhosting.com\/support\/edu\/cpanel\/how-to-log-into-cpanel\/\">Log into your cPanel interface<\/a>.\n<div style=\"clear: both;\"><\/div>\n<\/li>\n<li>Use the <a href=\"https:\/\/www.inmotionhosting.com\/support\/edu\/cpanel\/using-file-manager-in-cpanel\/\">cPanel File Manager<\/a> and navigate to your <em>modules\/upscarrier<\/em> folder.\n<div style=\"clear: both;\"><\/div>\n<\/li>\n<li>Locate the <em>upscarrier.php<\/em> file and <a href=\"https:\/\/www.inmotionhosting.com\/support\/website\/how-to-edit-a-file\/\">open it for editing<\/a>.\n<div class=\"alert\" style=\"color: red;\">It is highly recommended you make a copy of the file before making any changes<\/div>\n<div style=\"clear: both;\"><\/div>\n<\/li>\n<li>Once inside, locate the line of code below. It should be line 1180.\n<div class=\"code_block\">LEFT JOIN `\u2019._DB_PREFIX_.\u2019product_lang` pl ON (pl.`id_product` = p.`id_product` AND pl.`id_lang` = 2\u2032.(version_compare(_PS_VERSION_, \u20181.5.0\u2019) &gt;= 0 ? \u2018 \u2018.$this-&gt;context-&gt;shop-&gt;addSqlRestrictionOnLang(\u2018pl\u2019) : \u201d).\u2019)<\/div>\n<div style=\"clear: both;\"><\/div>\n<\/li>\n<li>Replace the entire line of code with the following line:\n<div class=\"code_block\">LEFT JOIN `\u2019._DB_PREFIX_.\u2019product_lang` pl ON (pl.`id_product` = p.`id_product` AND pl.`id_lang` = \u2018.$this-&gt;context-&gt;language-&gt;id.(version_compare(_PS_VERSION_, \u20181.5.0\u2019) &gt;= 0 ? \u2018 \u2018.$this-&gt;context-&gt;shop-&gt;addSqlRestrictionOnLang(\u2018pl\u2019) : \u201d).\u2019)<\/div>\n<div style=\"clear: both;\"><\/div>\n<\/li>\n<li>Once you have replaced the line of code, click on the <strong>Save Changes<\/strong> button in the upper right corner to save it.\n<div style=\"clear: both;\"><\/div>\n<\/li>\n<\/ol>\n<p>Now you can visit your \u2018<em>Connect to UPS<\/em>\u2018 module and view the <em>Product Settings<\/em> tab; the products will display in the dropdown properly.<\/p>\n<table class=\"article_table\" style=\"width: 100%;\">\n<tbody>\n<tr>\n<th>Before<\/th>\n<th>After<\/th>\n<\/tr>\n<tr>\n<td><a href=\"\/support\/images\/stories\/edu\/ps16\/errors\/modules\/upscarrier\/missing-products\/before.png\" rel=\"lightbox-0\"><img decoding=\"async\" class=\"std_ss\" title=\"Click here to view the larger image\" src=\"\/support\/images\/stories\/edu\/ps16\/errors\/modules\/upscarrier\/missing-products\/before.png\" alt=\"\" width=\"100%\"><\/a>\n<div style=\"clear: both;\"><\/div>\n<\/td>\n<td><a href=\"\/support\/images\/stories\/edu\/ps16\/errors\/modules\/upscarrier\/missing-products\/after.png\" rel=\"lightbox-0\"><img decoding=\"async\" class=\"std_ss\" title=\"Click here to view the larger image\" src=\"\/support\/images\/stories\/edu\/ps16\/errors\/modules\/upscarrier\/missing-products\/after.png\" alt=\"\" width=\"100%\"><\/a>\n<div style=\"clear: both;\"><\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>In this tutorial: What is the error? What causes it? How to fix it UPS is one of the most recognized names in the shipping industry. They are also a very common choice when shipping products to your customers. PrestaShop has modules for UPS so that you can use them for your shipping needs. There<a class=\"moretag\" href=\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\"> Read More ><\/a><\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[92],"tags":[4391],"class_list":["post-3229","post","type-post","status-publish","format-standard","hentry","category-prestashop","tag-prestashop-v1-6"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Fix: Missing Products in UPS Module Settings for PrestaShop | InMotion Hosting<\/title>\n<meta name=\"description\" content=\"Learn how to correct the missing products error in the UPS module for PrestaShop 1.6.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Fix: Missing Products in UPS Module Settings for PrestaShop | InMotion Hosting\" \/>\n<meta property=\"og:description\" content=\"Learn how to correct the missing products error in the UPS module for PrestaShop 1.6.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\" \/>\n<meta property=\"og:site_name\" content=\"InMotion Hosting Support Center\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/inmotionhosting\/\" \/>\n<meta property=\"article:published_time\" content=\"2014-05-02T20:16:12+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-08-17T03:01:42+00:00\" \/>\n<meta name=\"author\" content=\"Scott Mitchell\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@InMotionHosting\" \/>\n<meta name=\"twitter:site\" content=\"@InMotionHosting\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Scott Mitchell\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\"},\"author\":{\"name\":\"Scott Mitchell\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/person\/d850efb28ef3573db7d24b0d8fa9eaed\"},\"headline\":\"Fix: Missing Products in UPS Module Settings for PrestaShop\",\"datePublished\":\"2014-05-02T20:16:12+00:00\",\"dateModified\":\"2021-08-17T03:01:42+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\"},\"wordCount\":504,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#organization\"},\"keywords\":[\"Prestashop 1v.6\"],\"articleSection\":[\"Prestashop\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\",\"url\":\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\",\"name\":\"Fix: Missing Products in UPS Module Settings for PrestaShop | InMotion Hosting\",\"isPartOf\":{\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#website\"},\"datePublished\":\"2014-05-02T20:16:12+00:00\",\"dateModified\":\"2021-08-17T03:01:42+00:00\",\"description\":\"Learn how to correct the missing products error in the UPS module for PrestaShop 1.6.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.inmotionhosting.com\/support\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Fix: Missing Products in UPS Module Settings for PrestaShop\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#website\",\"url\":\"https:\/\/www.inmotionhosting.com\/support\/\",\"name\":\"InMotion Hosting Support Center\",\"description\":\"Web Hosting Support &amp; Tutorials\",\"publisher\":{\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.inmotionhosting.com\/support\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#organization\",\"name\":\"InMotion Hosting\",\"url\":\"https:\/\/www.inmotionhosting.com\/support\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.inmotionhosting.com\/support\/wp-content\/uploads\/2023\/02\/inmotion-hosting-logo-yoast.jpg\",\"contentUrl\":\"https:\/\/www.inmotionhosting.com\/support\/wp-content\/uploads\/2023\/02\/inmotion-hosting-logo-yoast.jpg\",\"width\":696,\"height\":696,\"caption\":\"InMotion Hosting\"},\"image\":{\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/inmotionhosting\/\",\"https:\/\/x.com\/InMotionHosting\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/person\/d850efb28ef3573db7d24b0d8fa9eaed\",\"name\":\"Scott Mitchell\",\"url\":\"https:\/\/www.inmotionhosting.com\/support\/author\/scott\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Fix: Missing Products in UPS Module Settings for PrestaShop | InMotion Hosting","description":"Learn how to correct the missing products error in the UPS module for PrestaShop 1.6.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/","og_locale":"en_US","og_type":"article","og_title":"Fix: Missing Products in UPS Module Settings for PrestaShop | InMotion Hosting","og_description":"Learn how to correct the missing products error in the UPS module for PrestaShop 1.6.","og_url":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/","og_site_name":"InMotion Hosting Support Center","article_publisher":"https:\/\/www.facebook.com\/inmotionhosting\/","article_published_time":"2014-05-02T20:16:12+00:00","article_modified_time":"2021-08-17T03:01:42+00:00","author":"Scott Mitchell","twitter_card":"summary_large_image","twitter_creator":"@InMotionHosting","twitter_site":"@InMotionHosting","twitter_misc":{"Written by":"Scott Mitchell","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#article","isPartOf":{"@id":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/"},"author":{"name":"Scott Mitchell","@id":"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/person\/d850efb28ef3573db7d24b0d8fa9eaed"},"headline":"Fix: Missing Products in UPS Module Settings for PrestaShop","datePublished":"2014-05-02T20:16:12+00:00","dateModified":"2021-08-17T03:01:42+00:00","mainEntityOfPage":{"@id":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/"},"wordCount":504,"commentCount":0,"publisher":{"@id":"https:\/\/www.inmotionhosting.com\/support\/#organization"},"keywords":["Prestashop 1v.6"],"articleSection":["Prestashop"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/","url":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/","name":"Fix: Missing Products in UPS Module Settings for PrestaShop | InMotion Hosting","isPartOf":{"@id":"https:\/\/www.inmotionhosting.com\/support\/#website"},"datePublished":"2014-05-02T20:16:12+00:00","dateModified":"2021-08-17T03:01:42+00:00","description":"Learn how to correct the missing products error in the UPS module for PrestaShop 1.6.","breadcrumb":{"@id":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.inmotionhosting.com\/support\/edu\/prestashop\/ups-module-misssing-products\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.inmotionhosting.com\/support\/"},{"@type":"ListItem","position":2,"name":"Fix: Missing Products in UPS Module Settings for PrestaShop"}]},{"@type":"WebSite","@id":"https:\/\/www.inmotionhosting.com\/support\/#website","url":"https:\/\/www.inmotionhosting.com\/support\/","name":"InMotion Hosting Support Center","description":"Web Hosting Support &amp; Tutorials","publisher":{"@id":"https:\/\/www.inmotionhosting.com\/support\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.inmotionhosting.com\/support\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.inmotionhosting.com\/support\/#organization","name":"InMotion Hosting","url":"https:\/\/www.inmotionhosting.com\/support\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/logo\/image\/","url":"https:\/\/www.inmotionhosting.com\/support\/wp-content\/uploads\/2023\/02\/inmotion-hosting-logo-yoast.jpg","contentUrl":"https:\/\/www.inmotionhosting.com\/support\/wp-content\/uploads\/2023\/02\/inmotion-hosting-logo-yoast.jpg","width":696,"height":696,"caption":"InMotion Hosting"},"image":{"@id":"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/inmotionhosting\/","https:\/\/x.com\/InMotionHosting"]},{"@type":"Person","@id":"https:\/\/www.inmotionhosting.com\/support\/#\/schema\/person\/d850efb28ef3573db7d24b0d8fa9eaed","name":"Scott Mitchell","url":"https:\/\/www.inmotionhosting.com\/support\/author\/scott\/"}]}},"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"primary_category":null,"_links":{"self":[{"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/posts\/3229","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/comments?post=3229"}],"version-history":[{"count":5,"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/posts\/3229\/revisions"}],"predecessor-version":[{"id":84279,"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/posts\/3229\/revisions\/84279"}],"wp:attachment":[{"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/media?parent=3229"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/categories?post=3229"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.inmotionhosting.com\/support\/wp-json\/wp\/v2\/tags?post=3229"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}