Do a select on the database using the fields you have as the where
clause and see if it returns anything.
set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open strConnectionString
set rsRecordset = Server.CreateObject("ADODB.Recordset")
sSQL = "SELECT * FROM [myTable] WHERE [myField] = 'myvalue' AND
[myField2] = 'myvalue2';"
rsRecordset.Open sSQL, objConn, adOpenForwardOnly, adLockReadOnly
if rsRecordset.EOF then
'Record doesn't exist
else
'Record does exist
end if
rsRecordset.close
objConn.close
set rsRecordset = nothing
set objConn = nothing
Dan
________________________________
From: [email protected]
[mailto:[EMAIL PROTECTED] On Behalf Of Jegatha
Sent: 08 June 2005 08:55
To: Asp
Subject: [AspClassicAnyQuestionIsOk] How to check?
Hi Friendz
need to check if the record is already exsist or not?
how to out it?,
thankz.
regards,
jegatha
---------------------------------
How much free photo storage do you get? Store your friends n family
photos for FREE with Yahoo! Photos.
http://in.photos.yahoo.com
[Non-text portions of this message have been removed]
________________________________
Yahoo! Groups Links
* To visit your group on the web, go to:
http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/
* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]
subscribe>
* Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service <http://docs.yahoo.com/info/terms/> .
[Non-text portions of this message have been removed]
------------------------ Yahoo! Groups Sponsor --------------------~-->
<!-- SpaceID=1705006764 loc=TM noad -->
--------------------------------------------------------------------~->
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/