Bind String > 4000 chars?

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
MarkF
Posts: 211
Joined: Thu 02 Mar 2006 14:55

Bind String > 4000 chars?

Post by MarkF » Wed 28 Oct 2009 11:27

I'm trying to get a bind var value from a plsql routine that returns more than 4000 characters. I can get up to 4000, but any more and I get

ORA-06502: PL/SQL: numeric or value error: character string buffer too small

My plsql code looks like:

Code: Select all

begin
  :MyVar := rpad('*',4001,'*');  -- Any val higher then 4000 fails.
  :MyVarLength := length(:MyVar);
end;
I'm using a parameter datatype of ftString. Is there a different datatype to use for plsqlstrings that could be up to 32767 chars? Thanks for any help!

-Mark

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Thu 29 Oct 2009 07:58

Set the UseMaxDataSize global variable from the OraClasses unit to False. Theoretically this should not has any side effects.

edwin
Posts: 19
Joined: Thu 08 Oct 2009 09:15

UseMaxDataSize / 4000 character limit

Post by edwin » Fri 06 Nov 2009 09:07

I'm having the same issue with one of the latest dotConnect releases.

Where can I find this setting UseMaxDataSize? Or is there another solution?

b-b
Posts: 10
Joined: Fri 19 Jul 2013 11:09

Re: Bind String > 4000 chars?

Post by b-b » Tue 23 Jul 2013 12:23

"Theoretically this should not has any side effects."

--> see: http://forums.devart.com/viewtopic.php?f=5&t=27581

Post Reply