KennyAround
Member
version: 10.2B
platform: Linux
The scenario is that I need to retrieve the first most recently confirmed records with the earliest order date. I need 1 record only to be displayed as default on some screens.
	
	
	
		
In the table above, the most recently confirmed record (25/May/2012) with the earliest order date is high-lighted. How to code to address that record?
Do I need to use "For Each...break by" and the First() function to get this record? or Is there any faster way to do so?
				
			platform: Linux
The scenario is that I need to retrieve the first most recently confirmed records with the earliest order date. I need 1 record only to be displayed as default on some screens.
		Code:
	
	define temp-table tTrack
 field account like customer.account
 field orderdate like order.orderdate
 field confirmdate like order.confirmdate.
.
.
account  orderdate   confirmdate
1231681  21/May/2012  25/May/2012
1392265  23/Mar/2012  25/Apr/2012
2409954  20/May/2012  25/May/2012
1684423  15/May/2012  25/May/2012
[COLOR=#ff0000][B]1759026  11/Apr/2012  25/May/2012[/B][/COLOR]<--
1849320  12/Mar/2012  25/Apr/2012
5906333  10/Jan/2012  25/Mar/2012
3260912  15/Mar/2012  25/Mar/2012
6263029  15/Feb/2012  25/Apr/2012In the table above, the most recently confirmed record (25/May/2012) with the earliest order date is high-lighted. How to code to address that record?
Do I need to use "For Each...break by" and the First() function to get this record? or Is there any faster way to do so?
 
	 
 
		