Title: Meta_query compare between two values
Last modified: August 21, 2016

---

# Meta_query compare between two values

 *  [Jeffrey van Rossum](https://wordpress.org/support/users/jeffreyvr/)
 * (@jeffreyvr)
 * [12 years, 6 months ago](https://wordpress.org/support/topic/meta_query-between-two-values/)
 * I’m using a query to check if the price of a product falls within a certain range.
   This works with the code below, until I use a zero value to compare from.
 *     ```
       array(
       	'relation' => 'OR',
       	   array('key' => 'buyprice'),
       	   array('key' => 'rentalprice'),
       	'value' => array( $_GET['price_start'], $_GET['price_end'] ),
       	'compare' => 'BETWEEN',
       	'type' => 'UNSIGNED'
       )
       ```
   
 * How can I get this to work when the ‘price_start’ value is 0? Hoping for help.

The topic ‘Meta_query compare between two values’ is closed to new replies.

## Tags

 * [between](https://wordpress.org/support/topic-tag/between/)
 * [meta_query](https://wordpress.org/support/topic-tag/meta_query/)
 * [price](https://wordpress.org/support/topic-tag/price/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [Jeffrey van Rossum](https://wordpress.org/support/users/jeffreyvr/)
 * Last activity: [12 years, 6 months ago](https://wordpress.org/support/topic/meta_query-between-two-values/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
