Try the HasRows property:
if (!$rdr.hasRows) {"Do something"}
--
Kiron
Try the HasRows property:
if (!$rdr.hasRows) {"Do something"}
--
Kiron
| Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| WMI query results not giving the expected result | Matabra | PowerShell | 3 | 08 Jul 2009 |
| LDAP Group Query Results Limitation | Bart Perrier | VB Script | 2 | 09 Apr 2009 |
| Testing for Query results | William Stokes | VB Script | 3 | 03 Dec 2008 |
| Re: ArrayList of REG QUERY results | Tao Ma | PowerShell | 1 | 29 May 2008 |
| Newbie: Nagios with nrpe_nt, check for diskspace; check services,returncode | Denny Schierz | PowerShell | 4 | 24 Jul 2006 |