[Lazarus] PostgreSql: unexpected EOF on client connection with an open transaction
Michael Van Canneyt
michael at freepascal.org
Wed Sep 2 16:55:24 CEST 2015
On Tue, 1 Sep 2015, Leonardo M. Ramé wrote:
> Hi, this is kind of a dejavu, I'm pretty sure I have asked this question
> before, but I can't find the old message, so, here I go.
> In my postgresql.log file I get this two messages every time I query/update
> the database:
> could not receive data from client: Connection reset by peer
> unexpected EOF on client connection with an open transaction
> I'm using TPQConnection/TSqlTransaction/TSqlQuery in a CGI with this method:
> procedure TDataModule1.ExecSql(ASql: string);
> lSql: TSQLQuery;
> lSql := TSQLQuery.Create(nil);
> lSql.DataBase := PQConnection1;
> lSql.Transaction := SQLTransaction1;
> lSql.SQL.Text:= ASql;
> The query is executed without issues, data is stored into the db, but I keep
> getting those messages.
Do you have a second transaction object (e.g. default transaction) ?
If so, that's probably it.
More information about the Lazarus