Database Find

littledump
06-05-2002, 03:38 PM
I have an ADO database & i use the find method. How do i know if the record was not found? The problem is, the database may be empty therefore i cant check BOF or EOF which i have tried

i have also tried looping through the database myself which for some reason doesnt work if the database is empty


Thanks for the help

Rezner
06-05-2002, 06:52 PM
Assuming you have already created and set your ADODB connection and recordset objects...<%
RS.Open "SELECT PrimaryKey FROM YourTable", conn, 3, 3, 1

If RS.RecordCount > 0 Then
Response.write "There are contents"
Else
Response.write "It's empty"
End if
%>

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum