Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Did the query return any rows
"Randy Harris" <randy_at_SpamFree.com> wrote in
news:1q8ke.90$3V.58_at_newssvr31.news.prodigy.com:
> I'm calling SQL*Plus to run a query from inside a Unix (ksh) script. How
> can I tell whether the query returned any rows or not?
>
>
By making "proper" use of SQL*Plus & the ability to generate a SPOOL file, I test for non-zero length of the output file. In other words zero rows results in a spool file of length 0. I use this approach daily in cron jobs Received on Sun May 22 2005 - 19:31:00 CDT
![]() |
![]() |