Title: Error UGS / ID
Last modified: May 22, 2025

---

# Error UGS / ID

 *  [jonathan66](https://wordpress.org/support/users/jonathan66/)
 * (@jonathan66)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/)
 * Hello everybody.
 * You have a major problem with the default option display. You’re confusing the
   product ID and its SKU.
 * So this automatically adds products that don’t belong in the bundle.
 * ![](https://wordpress.org/917c90b9-a715-421c-bac6-ba45c9604834)
 * ![](https://wordpress.org/9d359adf-c097-4d94-a893-e9f8916e18a9)
 * ![](https://wordpress.org/a4796c5a-b1b8-4f73-a9b1-936d21b9e4ae)
 * ![](https://wordpress.org/76dc88bf-aff1-4190-82ae-eda50db202b4)

Viewing 8 replies - 1 through 8 (of 8 total)

 *  [Janilyn Tran](https://wordpress.org/support/users/janilyn409/)
 * (@janilyn409)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18478949)
 * Hi [@jonathan66](https://wordpress.org/support/users/jonathan66/) ,
 * Could you kindly show some images of the backend settings and a link to your 
   published product for checking from my end here?
 * I have checked on our dev site, it’s working properly.
 * Best regards.
 *  Thread Starter [jonathan66](https://wordpress.org/support/users/jonathan66/)
 * (@jonathan66)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18479059)
 * Hello. I’m having trouble importing some images here.
 * Here’s a URL with the images. [https://imgur.com/a/iqacJ3O](https://imgur.com/a/iqacJ3O)
 * I did this with the latest version, 7.5.5. I restored my website when I noticed
   this problem.
 *  [Janilyn Tran](https://wordpress.org/support/users/janilyn409/)
 * (@janilyn409)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18480941)
 * Hi [@jonathan66](https://wordpress.org/support/users/jonathan66/) ,
 * You mentioned the SKU in your last thread, however, in your image, that’s UGS.
 * UGS is not the same as SKU for products. Youn might have confused SKU with UGS.
 * UGS (Universal Goods Specification) is a standard that defines the physical characteristics
   of a product, while SKU (Stock Keeping Unit) is a unique identifier used by businesses
   to manage their inventory. 
 * The SKU is listed at the end of each item on the search box. When a product doesnt’t
   have any SKU assigned, the product ID will be used: [https://prnt.sc/8cc6r_02nxv0](https://prnt.sc/8cc6r_02nxv0).
 * When searching for products to add to smart composite, our plugin will search
   and display both the Product ID and SKU as in this image: [https://prnt.sc/drbxhvaO9mc1](https://prnt.sc/drbxhvaO9mc1).
   The UGS won’t be considered in this case.
 * So I can confirm that our plugin is working fine and do not mix up SKU with product
   ID at all. It’s just that our plugin doesn’t regard the UGS instead of SKU.
 * Best regards.
 *  Thread Starter [jonathan66](https://wordpress.org/support/users/jonathan66/)
 * (@jonathan66)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18483368)
 * Hello.
 *  No, I’m not confusing SKU and SKU. UGS = SKU in French. (See image)
 * [https://imgur.com/a/CAI4hZP](https://imgur.com/a/CAI4hZP)
 * Let’s stick with the word SKU to avoid adding complexity. I’m simply telling 
   you that when I upgrade from version 7.5.4 to 7.5.5, you see BOTH the SKU and
   the product ID. I showed you the proof in my previous images.
 * Pay more attention to the previous images. In the “default option,” I only have
   one product. However, when I look at the smart composite product and the drop-
   down list, a product has been added called “Ph moins piscines… …” even though
   it shouldn’t be there.
 * I’m telling you that its SKU (602), coincidentally, is identical to the ID of
   the product “Tuyau PVC souple…” (602).
 * And I think that’s why I have 2 products when I only need 1.
 *  [Janilyn Tran](https://wordpress.org/support/users/janilyn409/)
 * (@janilyn409)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18491124)
 * Hi [@jonathan66](https://wordpress.org/support/users/jonathan66/) ,
 * Our developers responded that UGS is not a standard equivalence for SKU. It’s
   a translation, not an official equivalent term that can be treated the same as
   SKU when you switch to French. There are some other translations being used for
   SKU in Friench as well.
 * Possibly, our plugin could not recognize UGS as the translation of SKU. They 
   said it was difficult to identify the translated elements so our plugin will 
   use the universal elements to be sure.
 * If you are using a multilingual plugin for translating texts and phrases on your
   site, kindly make sure the translation of UGS as SKU is recognized properly in
   the other plugin settings.
 * For smart composite, any unique identified number will be treated as a way to
   search for and add products to the offer. There’s no distinct option dfor choosing
   which to be used separately as in our WPC Product Bundles plugin. Users can choose
   to search by product ID or SKU in that plugin though.
 * Our developers said they would consider this further if possible, however, I 
   must state in advance that this is dififcult to be modified as your preference
   as UGS is not really considered an official element for managing products’ inventory
   instead of SKU. Also, smart composite offer different sources of pulling products,
   so making options to choose the product ID or SKU separately as in smart bundles
   will be really hard to not affect other current users (we have over 30K now).
 * Best regards.
 *  Thread Starter [jonathan66](https://wordpress.org/support/users/jonathan66/)
 * (@jonathan66)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18491184)
 * Hello. The difference between UGS and SKU isn’t the issue. Why do you keep talking
   to me about this?Pretend I never mentioned it and let’s get back to the problem.
 *  If SKU (e.g., 602) has an equivalent Product ID (e.g., 602), then Problem.
 * Can you check this piece of code please?
 * file : class-woocoo.php line 426
 * if ( ! empty( $component[‘default’] ) ) {
   if ( is_numeric( $component[‘default’])){//
   ← 🚩 Problem HERE!!!!!!!!!!// id$product_default = wc_get_product( $component[‘
   default’] );} else {// sku$product_default = wc_get_product( wc_get_product_id_by_sku(
   $component[‘default’] ) );}
 *     ```wp-block-code
       if ( $product_default ) {
           echo '<option value="' . esc_attr( $component['default'] ) . '" selected="selected">' . wp_kses_post( $product_default->get_formatted_name() ) . '</option>';
       }
       ```
   
 * }
 * `is_numeric()` considers anything that looks like a number (e.g., `"1234"`) as
   a number.
 * So if your SKU is `"1234"` (which is a string of digits), it will pass this test.
 * But WooCommerce will then try to fetch a product using the ID `1234`:
 * `$product_default = wc_get_product( $component['default'] );`
 * … instead of using the function that searches by SKU:
    -  This reply was modified 1 year, 4 months ago by [jonathan66](https://wordpress.org/support/users/jonathan66/).
 *  Thread Starter [jonathan66](https://wordpress.org/support/users/jonathan66/)
 * (@jonathan66)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18491215)
 * Correction :
 * $product_id = wc_get_product_id_by_sku( $component[‘default’] );
   $product_default
   = wc_get_product( $product_id );
    -  This reply was modified 1 year, 4 months ago by [jonathan66](https://wordpress.org/support/users/jonathan66/).
 *  [Janilyn Tran](https://wordpress.org/support/users/janilyn409/)
 * (@janilyn409)
 * [1 year, 3 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18494082)
 * Hi [@jonathan66](https://wordpress.org/support/users/jonathan66/) ,
 * We do not provide any kind of technical customization on this forum cause we 
   do not have any technical developers available here. We can only help you with
   general questions about our plugin features.
 * What I said to you was what our developers said from our discussion about your
   case. I will send the information you gave to our developers so that they can
   further consider this case. Which action to take is dependent on our developers
   and their tests.
 * I cannot guarantee this can be fixed as you prefer. The final decision is up 
   to our developers. I can only write reports to them.
 * Best regards.

Viewing 8 replies - 1 through 8 (of 8 total)

 The topic ‘Error UGS / ID’ is closed to new replies.

 * ![](https://ps.w.org/wpc-composite-products/assets/icon-128x128.png?rev=2527543)
 * [WPC Composite Products for WooCommerce](https://wordpress.org/plugins/wpc-composite-products/)
 * [Support Threads](https://wordpress.org/support/plugin/wpc-composite-products/)
 * [Active Topics](https://wordpress.org/support/plugin/wpc-composite-products/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wpc-composite-products/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wpc-composite-products/reviews/)

 * 8 replies
 * 2 participants
 * Last reply from: [Janilyn Tran](https://wordpress.org/support/users/janilyn409/)
 * Last activity: [1 year, 3 months ago](https://wordpress.org/support/topic/error-ugs-id/#post-18494082)
 * Status: not resolved