Page 1 of 1

invalid byte sequence for encoding "SQL_ASCII": 0x00 (PostgreSQL Direct.NET 3)

Posted: Fri 04 May 2007 07:54
by mak12
I've installed PostgreSQL 8.2.4 under Slackware 11.
I use PostgreSQL Direct .NET 3 in my VB NET application (.NET Framework 1.1).
My application do a databinding with many fields on the database.
Now i've a problem with a rich text box and a formatted text.
With PostgreSQL 8.1.x and PostgreSQL Direct .NET 2 and 3 it work, but with PostgreSQL 8.2.x it give me an error when i try to update the database with CoreLab.PostgreSql.PgSqlDataAdapter.
The error is "invalid byte sequence for encoding "SQL_ASCII": 0x00".

This is source code :

'''''''''''''''''''''''''''''''''''''
Dim daPgs As CoreLab.PostgreSql.PgSqlDataAdapter
..
..
..
RowMod = daPgs.Update(dsSin, NomTabGen) 'This line cause the error

''''''''''''''''''''''''''''
In fact dsSin.Tables(0).Rows(0).RowError contain the error "invalid byte sequence for encoding "SQL_ASCII": 0x00".

dsSin is the DataSet and NomTabGen is the name of the dataset's table that contain data.

I tried to force an update with

ExecuteNonQuery("UPDATE fax SET msgfor='{\rtf1\ansi\ansicpg1252\deff0\deflang1040{\fonttbl{\f0\fnil\fcharset0 Microsoft Sans Serif;}}
\viewkind4\uc1\pard\f0\fs24 Prova\fs17\par
}
' WHERE idkey='219'")

And it throw this exception : "insufficient data left in message"

The database encoding is SQL_ASCII (but is the same on PostgreSQL 8.1.x!).

Thanks,
Marco Luoni

Posted: Mon 07 May 2007 06:37
by Alexey
Please send me a test project to reproduce the problem.
Include definition of your own database objects.
Use e-mail address provided in the Readme file.
Do not use third party components.

Posted: Wed 16 May 2007 08:00
by mak12
Are there any news?

Posted: Wed 16 May 2007 10:06
by Alexey
We are working on providing a solution.