It is true that the sample is the first execution before the sorting takes place. Oracle DB dose the same thing.
I was unsuccessfully trying to use sub-query in this case. Kathy -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bob Woodward Sent: Thursday, May 25, 2006 6:36 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] OK...Is there a way....UV Played around a bit and figured out that SSELECT adds "BY @ID" to the end of the select attributes, hence SSELECT FILE BY @ID is redundant. SSELECT FILE BY F2 is equivalent to SELECT FILE BY F2 BY @ID. In any case, it appears that SAMPLE has a higher execution priority in R/LIST processing, thereby forcing multiple lines in George's paragraph. Sorry George. BobW -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brad Davis Sent: Thursday, May 25, 2006 2:40 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] OK...Is there a way....UV Use two statements: 1>SSELECT FILE BY @ID 2>SELECT FILE SAMPLE 2 Or 1>SELECT FILE SAMPLE 2 2>SSELECT FILE BY @ID -----Original Message----- From: Bob Woodward [mailto:[EMAIL PROTECTED] Sent: Thursday, May 25, 2006 4:11 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] OK...Is there a way....UV Have you tried: SORT FILE SAMPLE 2 BobW -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of George Gallen Sent: Thursday, May 25, 2006 12:16 PM To: u2-users@listserver.u2ug.org Subject: [U2] OK...Is there a way....UV I want to sort a file by @ID and only take the first two items... SELECT FILE BY @ID SAMPLE 2 doesn't work, it first takes the sample of 2, then sorts it. SELECT FILE BY @ID SELECT FILE SAMPLE 2 works, but takes two lines How can I phrase my SELECT so it will sort first, then sample later, instead of sample first, sort later? I'm running UV. George George Gallen Senior Programmer/Analyst Accounting/Data Division [EMAIL PROTECTED] ph:856.848.1000 Ext 220 SLACK Incorporated - Delivering the best in health care information and education worldwide. http://www.slackinc.com ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/