Multiply Active Result Set (MARS)

Multiply Active Result Set (MARS)

Postby drzewieckil » Thu 21 Jan 2016 09:02

Hello,

I've noticed that using your driver to PostgreSQL it's possible to use MARS (ie many opened Data Readers in .net on the same connection). Using open source Npgsql driver though it's not possible.
I wonder how MARS is implemented in your driver and does it have an impact on performance?
Can I use it safetly on big data collections?
drzewieckil
 
Posts: 4
Joined: Mon 28 Apr 2014 11:33

Re: Multiply Active Result Set (MARS)

Postby Pinturiccio » Fri 22 Jan 2016 15:06

dotConnect for PostgreSQL does not support MARS. PgSqlDataReader must be closed before using the associated PgSqlConnection.

drzewieckil wrote:I've noticed that using your driver to PostgreSQL it's possible to use MARS (ie many opened Data Readers in .net on the same connection).

You could get such a situation in case if FeachAll=True (the default value). Whole resultset is read into buffer when executing a command, and then it is read from the buffer, and it's possible that the connection is ready to use again prior to closing the reader, but these are very special cases. In general PgSqlDataReader must be closed before using the associated PgSqlConnection.
Pinturiccio
Devart Team
 
Posts: 2020
Joined: Wed 02 Nov 2011 09:44

Re: Multiply Active Result Set (MARS)

Postby drzewieckil » Mon 25 Jan 2016 06:30

Thank you for your answer.

Do you plan to implement MARS in future versions?
drzewieckil
 
Posts: 4
Joined: Mon 28 Apr 2014 11:33

Re: Multiply Active Result Set (MARS)

Postby Pinturiccio » Mon 25 Jan 2016 12:27

We will investigate the possibility to support MARS but this feature isn't on our to do list, and no timeframe is available.
Pinturiccio
Devart Team
 
Posts: 2020
Joined: Wed 02 Nov 2011 09:44


Return to dotConnect for PostgreSQL