Re: # of rows in cursor
Posted in 1996
Daniel Wright — — source: Informix-list mailing list archive (1991-1998)
Ramiro Rela wrote: > > How can I get the number of rows in a cursor? > I4GL v4.10 > TIA. > Ramiro Well, if you haven't tried it yet, check out SQLCA.SQLERRD[5] (check that subscript, I may be wrong) after the OPEN statement. (If that doesn't work, which it may not, since it seems too easy, I think you're stuck with doing a SELECT COUNT(1), which will be terribly inefficient) ("SELECT COUNT(1)" s/b more efficient than SELECT COUNT(*)....In Informix, you should NEVER select more fields than you actually need.) The same does not necessarily apply to other SQLs. -danwright@bigfoot.com