MAX - 1

BigJimSlade

Registered User.
Local time
Today, 18:26
Joined
Oct 11, 2000
Messages
173
Hello, Big Jim here,

I was wondering if there is an easy way to find the 2nd most MAX value of a column. I could figure this out using some VB, but I was hoping there is an easier less stressful "function" to accomplish this task.

Thanks in advance...

Big Jim
 
This is what I found using sub queries.
Let Table be MyTable and numeric field be MyData.

SELECT Max(MyData) AS SecondMostMax
FROM MyTable AS T1
WHERE (((T1.MyData)<(SELECT Max(MyData) FROM MyTable T2 )));
 

Users who are viewing this thread

Back
Top Bottom