Title: sql syntax
Last modified: June 17, 2021

---

# sql syntax

 *  Resolved [edvardspektar](https://wordpress.org/support/users/edvardspektar/)
 * (@edvardspektar)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/sql-syntax-2/)
 * Hello, one little question if it is possible.
    We have your tab with quick query
   form on every product. But we forgot to put it on about 1000 products. Can you
   advize with 2 SQL codes that would do this:
 * 1. Check if tab is already opened under product and just fill it with some data.
   
   2. If tab is not opened then open it with it’s name and fill it with data. We
   have two languages via WPML so different query regarding the language code.
 * If it is not possible we would have to open every single product and do the thing
   manually. Can it be done?
    Thanks in advance, with regards.

Viewing 1 replies (of 1 total)

 *  [jpowersdev](https://wordpress.org/support/users/jpowersdev/)
 * (@jpowersdev)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/sql-syntax-2/#post-14583960)
 * Hi [@edvardspektar](https://wordpress.org/support/users/edvardspektar/),
 * The tab data is stored as serialized data, so it would be better to handle this
   in PHP (either as a wp-cli command or perhaps an admin page with some sort of
   trigger).
 * When loading the meta field (`yikes_woo_products_tabs`) it will be accessible
   as an associative array, so you can check for the slug of the tab you need and
   add it if it doesn’t exist. I can’t speak to the WPML interaction or how that
   will change the strategy.
 * As an alternative to the above strategy, our premium version of the plugin allows
   you to apply tabs to products based on taxonomy. In that scenario, you could 
   add a product tag to those products and assign the tab via the global tabs interface.
 * Let me know if that helps,
    Jon

Viewing 1 replies (of 1 total)

The topic ‘sql syntax’ is closed to new replies.

 * ![](https://ps.w.org/yikes-inc-easy-custom-woocommerce-product-tabs/assets/icon-
   256x256.png?rev=1558461)
 * [Custom Product Tabs for WooCommerce](https://wordpress.org/plugins/yikes-inc-easy-custom-woocommerce-product-tabs/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/yikes-inc-easy-custom-woocommerce-product-tabs/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/yikes-inc-easy-custom-woocommerce-product-tabs/)
 * [Active Topics](https://wordpress.org/support/plugin/yikes-inc-easy-custom-woocommerce-product-tabs/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/yikes-inc-easy-custom-woocommerce-product-tabs/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/yikes-inc-easy-custom-woocommerce-product-tabs/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [jpowersdev](https://wordpress.org/support/users/jpowersdev/)
 * Last activity: [4 years, 11 months ago](https://wordpress.org/support/topic/sql-syntax-2/#post-14583960)
 * Status: resolved