Solved

MySQL: Get Range Where there are Two or More Matches

Posted on 2013-05-16
1
260 Views
Last Modified: 2013-05-16
Using MySQL, I would like to get the range ( max - min ) for values.

The problem with my query is that I want it to return NULL if there are less than 2 matches for the time period.

In this example, the value of "BIDRANGE4" should be NULL not 0.

http://sqlfiddle.com/#!2/94d35/1
0
Comment
Question by:hankknight
1 Comment
 
LVL 40

Accepted Solution

by:
Sharath earned 500 total points
ID: 39172442
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
MYSQL simple update statement 3 53
setup wamp server for first time 2 70
Trigger usage 2 69
MS Access - need to reduce row size 25 52
Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question