Re: [cx-oracle-users] ORA-01461: can bind a LONG value only for insert into a LONG column
Brought to you by:
atuining
From: Anthony T. <ant...@gm...> - 2008-11-07 14:40:47
|
Hi, Can you specify what version of cx_Oracle you are using? There have been a few improvements over the years... :-) No matter what version you are using, though, you can always use setinputsizes() to specify. In other words, something like this: cursor.setinputsizes(thevalue = cx_Oracle.LONG_BINARY) cursor.execute("insert into thetable (thecolumn) values (:thevalue)", thevalue = "X" * 60000) That should work for you. You can see some of these techniques in the test suite as well. Anthony On Fri, Nov 7, 2008 at 6:55 AM, Vladislav Nazarenko <vla...@go...> wrote: > Hello! > > I have a little question... I'm trying to write a zip file in a oracle > db(9.2.x.x)... The Column type is LONG ROW... > > If the file size is smaller than 10 K, I have no troubles, but if it's > more, I get the following error: > > ORA-01461: can bind a LONG value only for insert into a LONG column > > The Column can take 70 K > > Query: > insert [TABLE NAME] ( test_column ) values ( utl_raw.cast_to_row([file > content]) ) > > > Could you please explain me, how can I avoid this ... > > Thanks a lot > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > cx-oracle-users mailing list > cx-...@li... > https://lists.sourceforge.net/lists/listinfo/cx-oracle-users > |