Page 1 of 1

Error when inserting/updating TimeStamp array with null valu

Posted: Fri 01 Jun 2012 11:18
by rliberoff
Hi,

I'm trying to insert or update a TimeStamp Without Time Zone column in the database with ´null´ values. But each time I execute the C# code, it throws the following error inside a Devart.Data.PostgreSql.PgSqlException class exception: {Error: 08P01: insufficient data left in message}

As an example, I have the following C# source code:

Code: Select all


public void Update()
{
    using (PostgreSQLCommand updateCommand = new PostgreSQLCommand((PgSqlConnection)transaction.Connection, GetStoredProcedureName(@"Schema", @"Update")))
    {         
       // The following parameter will have 26 'null' values/elements.                              
       updateCommand.Command.Parameters.Add(new PgSqlParameter(@"date", PgSqlType.Array) { Value = new PgSqlArray(PgSqlType.TimeStamp, 1, 26) });
       updateCommand.ExecuteNonQuery(true);                
    }
}

What I'm trying to do is quite simple: I could have 'null' values that I need to update through a stored procedure into a table using arrays for "bulk processing". So far, for debugging purposes the stored procedure is empty (no body).

Any help you could provide would be greatly appreciated.

Technical information:
- Microsoft Windows System
- PostgreSQL 9.1.2, compiled by Visual C++ build 1500, 64-bit
- Devart dotConnect for PostgreSQL 5.80.350.0

Error when inserting/updating TimeStamp array with null valu

Posted: Mon 04 Jun 2012 08:05
by rliberoff
Hi,

Anyone from Devart that can help us with this issue?

Re: Error when inserting/updating TimeStamp array with null

Posted: Wed 06 Jun 2012 12:31
by Pinturiccio
We have reproduced the issue. We will investigate it and notify you about the results as soon as possible.

Re: Error when inserting/updating TimeStamp array with null valu

Posted: Mon 18 Jun 2012 10:22
by aegeavaz
Hi,

Any progress about this issue? We got stuck in our development due to this issue so we would like a fix or a workaround to have this working.

Thanks!

Regards.

Re: Error when inserting/updating TimeStamp array with null valu

Posted: Mon 18 Jun 2012 11:56
by Pinturiccio
We have fixed the bug with insertion of the PgSqlArray instance containing elements with values equal to 'null'. We will post here when the corresponding build of dotConnect for PostgreSQL is available for download.

Re: Error when inserting/updating TimeStamp array with null valu

Posted: Thu 21 Jun 2012 13:19
by Pinturiccio
The new build of dotConnect for PostgreSQL 6.0.25 is available for download now!
It can be downloaded from http://www.devart.com/dotconnect/postgr ... nload.html (trial version) or from Registered Users' Area (for users with valid subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?t=24361