Hi,
I'm evaluating unidac (odbc connection to Pervasive SQL) in XE5
I try to build webserverapplication as standalone VCL appliction and have simple WebModule.
Server and queries work fine at runtime, but when closing server application I get AV in TCriticalSection.Acruire.
Here is simplified code, which causes error.
procedure TWebModule1.WebModule1WebActionItem2Action(Sender: TObject;
Request: TWebRequest; Response: TWebResponse; var Handled: Boolean);
var
I: Integer;
uc : TUniConnection;
uq : TUniQuery;
begin
uc := TUniConnection.Create(nil);
with uc do
begin
ProviderName := 'ODBC';
Server := 'OmaDb';
Connected := True;
LoginPrompt := False;
end;
uq := TUniQuery.Create(nil);
uq.Connection := uc;
uq.SQL.Text := 'select nimi, hinta from tuote where numero = :n';
begin
for I := 0 to request.QueryFields.Count-1 do
begin
uq.ParamByName('n').AsString :=request.QueryFields.strings;
uq.Open;
uq.Close;
end;
end;
response.ContentType := 'text/html';
response.Content := res;
uq.free;
uc.Disconnect;
uc.Free;
handled := true;
end;
I tested same code in normal VCL form event and didn't get any AV while closing app.
UniDac in WebModule
Re: UniDac in WebModule
This error also happened on Pervasive's own TPvQuery, so problem might be something else
Re: UniDac in WebModule
Hello,
The problem may be due to the ODBC driver. Please try to use another driver version.
The problem may be due to the ODBC driver. Please try to use another driver version.