PluginUs.Net - Business Tools for WooCommerce and WordPress

[realize your idea - make your dreams come true]

Support Forum

You need to log-in to create request (topic) to the support

Filter all products without sale

The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday. If you have problems with registration ask help on contact us page please
If you not got email within 24~36 business hours, firstly check your spam box, and if no any email from the support there - back to the forum and read answer here. DO NOT ANSWER ON EMAILS [noreply@pluginus.net] FROM THE FORUM!! Emails are just for your info, all answers should be published only here.
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday.

Hello,

I want to edit all products that are not currently on sale. Unfortunately, I have no idea how to do this. I have tried various combinations with the fields (sale price from, sale price to), but without success.

This solution also does not work:
https://bulk-editor.com/how-to-work-with-the-products-which-has-sale-price#/woot-gallery-woof

After using it, all products appear, including those without a promotion.

About"How to work with the products which HAS sale price":

Short video: https://screenrec.com/share/2GTz06AILa

_____

About"How to work with the products which HASN'T sale price":

Expectations: To filter all products that are not on sale, enter 0 in the"sale price to" field. Although I think the best solution would be to add a logical field for this case.

Hello

Although I think the best solution would be to add a logical field for this case - thank you for your suggestion

So you resolved your task? All you need is set"sale price to" -> 0 and you will see all products that not in sale

 

Unfortunately the solution I described is what I expected, unfortunately all products are displayed.

I have 3 types of product prices:
1. Without sale price
2. PLN 99
3. PLN 69

CASE 1:
Sale price to: Any number from 0 to 68:
Result: All products are displayed

CASE 2:
Sale price to: 69
Result: Products with sale price = 69 are displayed

CASE 3:
Sale price to: 99
Result: Products with sale price = 69 and 99 are displayed

CASE 4:
Sale price from: 97
Sale price to: 98

Result: All products are displayed [IMHO no products should be displayed]

____

Since in the table under the"Sale price" column there are products that have Sale Price value 0.00 (this value cannot be completely cleared), I expect that in the above case for sale price to: Any number from 0 to 68 should display the product have Sale Price = 0.00.

Hello

Ok, looks like exact feature not exist in the plugin, but on my side suggested way above works, I think that maybe all that products you need never has sale price and their meta _sale_price not exists, so I can suggest you the same way BUT firstly set real 0 to db to all products which has not sale price, execute next script firstly:

$args = array(
'post_type' => 'product',
'posts_per_page' => -1, 
'meta_query' => array(
'relation' => 'OR',
array(
'key' => '_sale_price',
'compare' => 'NOT EXISTS',
),
array(
'key' => '_sale_price',
'value' => '',
'compare' => '=' 
),
array(
'key' => '_sale_price',
'value' => '0',
'compare' => '=' 
),
),
);

$query = new WP_Query($args);

if ($query->have_posts()) {
while ($query->have_posts()) {
$query->the_post();
$product_id = get_the_ID();

update_post_meta($product_id, '_sale_price', '0');
}
}

wp_reset_postdata();