I can write SQL queries in ASP no problem but I have one that I need to run within Enterprise Manager as it will timeout if I call it from an ASP. Can someone help me with the syntax?
Is this just as simple as typing in the following? I am guessing I may need single or double quotes around the UserName but not quite sure.Code:<% dim strUserName strUserName = "isisTraffic" then szStatement = "execute dbo.ap_DeleteDynamicResource '" + strUserName + "'" set conn = createobject("ADODB.Connection") conn.provider = "sqloledb" conn.connectionstring = "data source="& DB &";uid="& UID &";pwd="& PWD &";initial catalog=site_security" conn.open conn.execute(szStatement) conn.close set conn = nothing %>
execute dbo.ap_DeleteDynamicResource strUserName