Consumes a lot of memory when execute Select SQL which takes a long time

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for PostgreSQL
Post Reply
Tachiro
Posts: 5
Joined: Tue 28 Apr 2020 11:56

Consumes a lot of memory when execute Select SQL which takes a long time

Post by Tachiro » Mon 21 Sep 2020 11:00

I have a "Select" SQL statement.
It will take a long time. (more than 3 minutes)

When I execute it on pgAdmin III, it won't consumes a lot of memory.
But "dotConnect for PostgreSQL Express 7.18.1730" will.
(I use the sample code of "dotConnect for PostgreSQL - DataReader".)

The same problem happened to "dotConnect for Oracle Standard 9.13.1098".


Best Regards,
Tachiro

Image
Last edited by Tachiro on Thu 12 Nov 2020 11:38, edited 2 times in total.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: Consumes a lot of memory when execute Select SQL which takes a long time

Post by Shalex » Thu 24 Sep 2020 15:21

pgAdmin III may fetch data on a per-page basis while dotConnect for PostgreSQL retrieves the full result set.

You can set PgSqlCommand.FetchAll=false and control a number of rows that will be transferred across the network at a time via PgSqlCommand.FetchSize. Refer to https://www.devart.com/dotconnect/postg ... mbers.html.

Post Reply