470,599 Members | 1,499 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,599 developers. It's quick & easy.

"Connection is dead" on ODBC insert of decimal into DB2

I am having problems inserting Decimal values into a DB2 database via
a .NET/C# application which is using an OdbcDataAdapter. Other field
types such as VarChar, Int, Date, etc work ok, and I can insert
literal values into a decimal field, but any attempt to insert a
decimal field via an OdbcParameter causes a
System.InvalidOperationException ("The connection is dead") to be
thrown by the DbDataAdapter.Update method.

The ODBC driver is IBM's DB2 Connect Personal Edition, Version 5
(installed as part of IBM DB2 Universal Database for Windows NT,
Version 5).

A typical failing OdbcParameter follows:

new System.Data.Odbc.OdbcParameter(
System.Data.DataRowVersion.Current, null));

The database field is defined as DECIMAL 4 in the DB2 database.

Has anyone come across this before? Any suggestions for fixes or

Many thanks in advance,


Posted to: microsoft.public.dotnet.framework.odbcnet +
Nov 12 '05 #1
0 2134

This discussion thread is closed

Replies have been disabled for this discussion.

By using this site, you agree to our Privacy Policy and Terms of Use.