× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I need one record (style, class) with the greatest qty for style and
class. I don't need to return the qty.

I'm not able to get the syntax for your example right.

On Tue, May 29, 2018 at 8:56 PM, Alan Shore <ashore@xxxxxxxx> wrote:

HI Art
Just realized
Are you asking for the one record with the highest qty or the styles and
classes with the highest qty for each style and class (which is what I just
gave you)



Sent via the Samsung GALAXY S® 5, an AT&T 4G LTE smartphone


-------- Original message --------
From: Alan Shore <ashore@xxxxxxxx>
Date: 5/29/18 8:46 PM (GMT-05:00)
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>
Subject: RE: [EXTERNAL] Sql select max value question

HI Art

Not near a machine at the moment, but what you are asking for is to
compare the same file against itself where a.style = b.style and a.class =
b.class and a.qty gt or = max (b.qty)
I had to use gt
Cannot find the greater than sign

Hope this makes sense


Sent via the Samsung GALAXY S® 5, an AT&T 4G LTE smartphone


-------- Original message --------
From: "Art Tostaine, Jr." <atostaine@xxxxxxxxx>
Date: 5/29/18 8:30 PM (GMT-05:00)
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>
Subject: [EXTERNAL] Sql select max value question

I have a table with 3 columns, style, class, quantity

There are many classes for each style. I want my select to return only the
class with the highest quantity.

I've been playing with max(qty) and fetch first row only from examples I
found on the web but can't get exactly what I want.

Thanks

--
Art Tostaine
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.