EAccessViolation inside TpgQuery

Discussion of open issues, suggestions and bugs regarding PgDAC (PostgreSQL Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Wodzu
Posts: 23
Joined: Thu 01 Sep 2011 08:35

EAccessViolation inside TpgQuery

Post by Wodzu » Fri 10 Jun 2016 14:59

Hello,

Steps to reproduce:

1. Make basic program, one TPgConnection, one simple TPgQuery.
2. Compile and run program under Delphi with debugging.
3. PgConnection1.Connected := True;
4. Go to services (in Windows) and stop postgresql-x64-9.4 - PostgreSQL Server 9.4 service. (Your program should still running).
5.PgQuery1.ExecSQL;

Now you will receive a series of exceptions. One of them will be: "Project <your project name> raised exception class EAccessViolation with message 'Access violation at address 00544079 in module 'your module name>. Read of address 00000050"

There is something wrong in the TPgQuery component. Please take a look at this. I have a working example but there is no way to include it here. I hope that I've explained how to reporduce the error.

My platform is: Windows 7, 64 bit, Delphi 2009.

Best regards.

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Re: EAccessViolation inside TpgQuery

Post by AlexP » Tue 14 Jun 2016 10:22

Hello,

We can't reproduce the issue on the latest PgDAC version 4.7.23. On an attempt to execute a query after server stop, a correct message is returned:
Error on data writing to the connection: An existing connection was forcibly closed by the remote host. Socket Error Code: 10054($2746)
Check this behavior on the latest PgDAC version.

Wodzu
Posts: 23
Joined: Thu 01 Sep 2011 08:35

Re: EAccessViolation inside TpgQuery

Post by Wodzu » Wed 15 Jun 2016 08:53

Hello,

I've tested it in 4.7.23. and the same error happens. Have you tested it under the debugger?

Under this link you will find a sample program and a short video with steps to reproduce:
https://drive.google.com/open?id=0ByKpG ... HBST0hIUFU

Hope that helps,

regards.

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Re: EAccessViolation inside TpgQuery

Post by AlexP » Wed 15 Jun 2016 10:33

Thank you for a sample. We have reproduced and fixed the issue.

Wodzu
Posts: 23
Joined: Thu 01 Sep 2011 08:35

Re: EAccessViolation inside TpgQuery

Post by Wodzu » Wed 15 Jun 2016 11:21

Excellent news, thanks guys!

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Re: EAccessViolation inside TpgQuery

Post by AlexP » Wed 15 Jun 2016 11:44

You are welcome. Feel free to contact us if you have any further questions.

HoKoWo
Posts: 5
Joined: Sat 23 Apr 2016 15:40

Re: EAccessViolation inside TpgQuery

Post by HoKoWo » Mon 20 Jun 2016 20:30

One little question, where can I download the debugged version of the component? In my download portal (I have subscription) is the version from April, 28th 2016 (4.7.23) only available for download. :?:

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Re: EAccessViolation inside TpgQuery

Post by AlexP » Tue 21 Jun 2016 08:36

We'll try to release a new build with this fix by the end of the month.

HoKoWo
Posts: 5
Joined: Sat 23 Apr 2016 15:40

Re: EAccessViolation inside TpgQuery

Post by HoKoWo » Tue 21 Jun 2016 21:55

Ok, thank you for your reply.

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Re: EAccessViolation inside TpgQuery

Post by AlexP » Wed 22 Jun 2016 08:05

You are welcome. Feel free to contact us if you have any further questions.

Post Reply