![]() |
Sergey Kornilov admin 9/11/2006 |
Try the following: '** Check if specific record exists **** *strSQLExists = "select from Projects where Project_Number = '" & dict("Project_Number") & "'"** set rsExists = CreateObject("ADODB.Recordset") rsExists.Open strSQLExists, dbConnection if not rsExists.eof then ' if record exists do something Respone.write "This Project Number already Exist" BeforeAdd=False else ' if dont exist do something else end if rsExists.Close : set rsExists = Nothing BeforeAdd = True |
G
|
gzusfreak author 9/12/2006 |
Thanks, I added the text: |
J
|
Jane 9/13/2006 |
Hi, |
G
|
gzusfreak author 9/13/2006 |
Is this what you need? Or do you need me to send you a zip file of all of the pages? |
![]() |
Sergey Kornilov admin 9/13/2006 |
If Project_Number is a numeric field you need to remove single quotes around it. |
G
|
gzusfreak author 9/13/2006 |
I am getting closer. I removed the single quotes and got this error: |
J
|
Jane 9/14/2006 |
To print SQL queru use Response.Write clause: '** Check if specific record exists **** strSQLExists = "select * from Projects where Project_Number = '" & dict("Project_Number") & "'" set rsExists = CreateObject("ADODB.Recordset") Response.Write strSQLExists |