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

Home -> Community -> Usenet -> c.d.o.server -> Re: Perplexing ORA-01461

Re: Perplexing ORA-01461

From: Daniel Morgan <damorgan_at_x.washington.edu>
Date: Fri, 12 Dec 2003 12:02:25 -0800
Message-ID: <1071259254.443540@yasure>


Haximus wrote:
> "Daniel Morgan" <damorgan_at_x.washington.edu> wrote in message
> news:1071252079.66421_at_yasure...
>

>>Haximus wrote:
>>
>>
>>>I'm working on a Forms 9i application, the db used is Oracle9i

>
> Enterprise
>
>>>Edition 9.2.0.4.0 running on RedHat AS 3.0.  I keep getting an ORA-01461
>>>error, which is defined as "can bind a LONG value only for insert into a
>>>LONG column."  The perplexing part is none of the columns in the table

>
> being
>
>>>inserted are defined as LONG, nor are any of the variables I'm using.

>
> I've
>
>>>searched metalink and tried some of the suggested fixes but no joy.
>>
>>How about CLOB? BLOB? etc? What data types do you have?

>
>
> This is the table definition itself:
>
> --- snip ---
> create global temporary table tree (
> id number not null primary key,
> parent_id number,
> rid rowid,
> seq number,
> selected char(1),
> type char(1),
> state number,
> label varchar(100),
> value number,
> block varchar(30),
> item varchar(30),
> branch varchar(100),
> options varchar(10),
> expr1 varchar(1000),
> expr2 varchar(1000),
> expr3 varchar(1000),
> check ( type in ('F','R') ),
> check ( state between -1 and 1 )
> )
> on commit preserve rows;
> --- unsnip ---
>
> The offending code looks something like this (edited for brevity);
>
> --- snip ---
> procedure insert_node(pnode tree%rowtype) is
> cnode tree%rowtype;
> begin
> -- assign some values to pnode
> select seq.nextval into cnode.id;
> cnode.parent_id := pnode.id;
> cnode.type := 'F';
> cnode.selected := 'N';
> cnode.state := 0;
> ...
> insert into tree values (cnode); -- <<<< this is where the ORA-01461
> occurs
> ...
> end;
> --- unsnip ---

I'd suggest you start with the following query:

SELECT keyword
FROM v$reserved_words
WHERE keyword IN ('ID', 'TYPE');

-- 
Daniel Morgan
http://www.outreach.washington.edu/ext/certificates/oad/oad_crs.asp
http://www.outreach.washington.edu/ext/certificates/aoa/aoa_crs.asp
damorgan_at_x.washington.edu
(replace 'x' with a 'u' to reply)
Received on Fri Dec 12 2003 - 14:02:25 CST

Original text of this message

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