Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> Help: UPDATE CLOB w/ NULL value errors

Help: UPDATE CLOB w/ NULL value errors

From: David Bennion <davidbennion_at_my-deja.com>
Date: Thu, 08 Feb 2001 18:05:13 GMT
Message-ID: <95un4f$3v7$1@nnrp1.deja.com>

Hello all. I hope there is someone out there who knows the answer to this.

I am getting a "Not enough storage space availble to complete this operation" error when I try to run and update with parameters on a table with 2 CLOBs in it where one of the clobs i'm inserting is just a null.

Here is VB code that reproduces the problem, since most of you probably aren't fortunate enough to be using Delphi. :)

David Bennion.
davidbennion_at_nospam.hotmail.com

VB example code follows


Dim conn As New ADODB.Connection
Dim cmd As New ADODB.Command

Dim Param1 As Variant
Dim Param2 As Variant
Dim Param3 As Variant

Rem you can create the table used for this by executing the following Rem Create table clobtest ( id integer, clob1 clob, clob2 clob)

conn.Open "Provider=OraOLEDB.Oracle;Persist Security Info=False;User ID=scott;Password=tiger;Data Source=MyDataSource;"

cmd.ActiveConnection = conn

Set Param1 = cmd.CreateParameter("clob1", 201, 1, 2147483647)
Set Param2 = cmd.CreateParameter("clob2", 201, 1, 2147483647)
Set Param3 = cmd.CreateParameter("id", 131, 1, 19)

Param1.Value = "non-null"

Param2.Value = Null
Param3.Value = 1
cmd.Parameters.Append (Param1)
cmd.Parameters.Append (Param2)
cmd.Parameters.Append (Param3)

cmd.CommandText = "update clobtest set clob1=?, clob2=? where id=?"

cmd.Execute

Sent via Deja.com
http://www.deja.com/ Received on Thu Feb 08 2001 - 12:05:13 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US