× 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.



Hi,

A result of an sql command is returning multiple rows from a transaction file like this :

Client Date Amount
Client1 79899898 100
Client1 79909898 10
Client1 79919898 100
Client1 79929898 900

How can I get the amount from the first row? This corresponds to the last entry, as the date field is numeric and equal to 99999999 - date field. I have a key on this field, but no way of joining to it from my client file.

At the moment, I'm running a WITH T As ( ) kind of expression on the transaction file to get the minimum date value for a client and then joining to that.

This makes for a very long execution time. Surely there's a better way?

Thanks

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.