|
Elvis, Rick: Thanks for your answers. That's what I thought of, although there is (was?) always hope :-) ? I wonder what would be faster, using a DDS-based LF or Elvis' proposed solution? This CL is executing a 5 sec. loop, and I wanted to avoid the sequence of CALL/Open Cursor (or file), etc. Thanks again, Luis Rodriguez midrange-l-request@xxxxxxxxxxxx wrote:------------------------------ message: 9 date: Tue, 27 Mar 2007 08:11:56 -0500 from: subject: RE: Getting the number of records in non-keyed logical files? Luis, Because views are merely SQL statement containers there are no records to count. Each time the view is accessed the SQL statement is executed to retrieve the resulting data set. To get the number of records you will need to count the number of records returned by the SQL statement contained in the view as posted by Elvis. Rick -----Original Message----- On Behalf Of Elvis Budimlic Sent: Monday, March 26, 2007 11:17 PM To: 'Midrange Systems Technical Discussion' Subject: RE: Getting the number of records in non-keyed logical files? I realize it's not purely CL solution, but if ILE is not out of the realm of possibilities doing a CALLPRC to a module written in HLL with embedded SQL following statement would be my choice: SELECT COUNT(*) FROM YOURVIEW Elvis Celebrating 10-Years of SQL Performance Excellence -----Original Message----- Subject: Getting the number of records in non-keyed logical files? Hi all, Does anybody know how to get the number of records in non-keyed logical files (e.g. SQL views)? RTVMBRD / NBRCURRCD can only get the number of records for keyed LFs. I would like to determine, in a CL program, the number of records in a SQL view. Thanks, Luis Rodriguez Luis Rodriguez IBM Certified Systems Expert eServer i5 iSeries Technical Solutions --------------------------------- No need to miss a message. Get email on-the-go with Yahoo! Mail for Mobile. Get started.
As an Amazon Associate we earn from qualifying purchases.
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.