"Jeremy Smith" <godtoall RemoveThis @hotmail.com> wrote in message
news:1108486564.157405.160400@f14g2000cwb.googlegroups.com...
> This might be an ASP group question, looking to IIS group on how to
> troubleshoot problem below.
>
> When the backend SQL server stops fulfilling the request below, my
> w3wp.exe hit %100 CPU, IIS recycle the application pool and then the
> new w3wp.exe goes to %100 CPU. The DBAs restart SQL and everything
> works fine. This only happens once a week. Curious to know why the
> below code would max the cpu out. Thanks for any help. I can give more
> detailed information if needed.
>
>
> 'setup connections
> set connFooter = Server.CreateObject ("ADODB.Connection")
> connFooter.open gConnString
>
> 'get URL so I know what row to update
> strPage = request("URL") 'obviously I prefer the real URL
> if strPage = "" then strPage = request("SCRIPT_NAME") 'all below are
> alternates
> if strPage = "" then strPage = request("PATH_INFO")
> if strPage = "" then strPage = request("PATH_TRANSLATED")
> if strPage = "" then strPage = "Unknown"
>
> 'get current count for this page
> strSQL = "use DB select field from TBL WITH (NOLOCK) where PAGE = '" &
> strPage & "'"
> set rsFooter_meCount = connFooter.execute (strSql)
What does your connection string look like?
Is your field actually named "field"? Isn't that reserved?
What are the purposes of "use DB" and "WITH (NOLOCK)"? I don't ever use
those statements (keep in mind I'm not a SQL expert) ...<!-- ~MESSAGE_AFTER~ -->
>> Stay informed about: asp page IIS 6.0 and SQL 2000