How to access MSSQL through ISAPI Filter
- From: "Kees de Winter" <nospam>
- Date: Fri, 31 Mar 2006 16:09:50 +0200
HI,
From my ISAPI filter, I am trying to connect to MSSQL Server (using delphi
5/IIS). But it is crashing my webserver all the time. Already the first line
of code below does that.
procedure InitializeDBConnection;
begin
try
adoConnection := TAdoConnection.Create(adoConnection);
adoConnection.Close;
adoConnection.ConnectionString := GetConnStringFromRegistry;
adoConnection.LoginPrompt := false;
adoConnection.Open;
adoQuery := TAdoQuery.Create(adoQuery);
adoQuery.Connection := adoConnection;
InitializeCriticalSection(CS);
except
On E: Exception do WriteLogFile('ERROR : ' + E.Message);
end;
end;
Here, adoConnection, adoQuery and CS are global vars, I thought I could
reuse these connections.
What am I doing wrong (using Delphi 5 / IIS 5)?
All help much appreciated.
--
Kees de Winter
.
Relevant Pages
- Re: TADOConnection LogInPrompt
... interesting thing is that if I set loginprompt to true then I get the ... It's as if the ADOConnection and the ADOQuery are both ... Pascal before that) and I've been using ADO components to access Access ... (borland.public.delphi.database.ado) - Re: How to access MSSQL through ISAPI Filter?
... First I thought I also had to use a Critical Section but it seems that Critical Sections are not necessary because the adoConnection and adoQuery variables in your example are local variables. ... Here, adoConnection, adoQuery and CS are global vars, I thought I ... could reuse these connections. ... (borland.public.delphi.database.ado) - Re: How to access MSSQL through ISAPI Filter?
... Kees de Winter wrote: ... adoConnection:= TAdoConnection.Create; ... Here, adoConnection, adoQuery and CS are global vars, I thought I ... What am I doing wrong (using Delphi 5 ... (borland.public.delphi.database.ado) - Connections with Gupta hangs
... I create a ADOConnection and then I execute an ADOQuery. ... the ADOQuery and the ADOConnection and move on to the next store. ... ADOStoreConnection.CursorLocation:= clUseClient; ... (borland.public.delphi.database.ado) - How to access MSSQL through ISAPI Filter?
... procedure InitializeDBConnection; ... adoConnection:= TAdoConnection.Create; ... Here, adoConnection, adoQuery and CS are global vars, I thought I could reuse these connections. ... Kees de Winter ... (borland.public.delphi.database.ado) |
|