• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

oracle stored procedure problem in 9i

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
this is related to java stored procedure
i get the error
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
when running the following procedure
variable a1 varchar2
exec call_func(:a1)
procedure call_func(p_name out char)
as
begin
p_name:=oscar_quote();
end;
FUNCTION oscar_quote RETURN varchar2
AS LANGUAGE JAVA
NAME 'Oscar.quote() return java.lang.char';
public class Oscar
{
public static String quote()
{
return "Hello how do you do";
}
}
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

variable a1 varchar2
exec call_func(:a1)
procedure call_func(p_name out char)
as
begin
p_name:=oscar_quote();
end;


Just out of curiosity why is the variable a1 a VARCHAR2 but the parameter p_name is a CHAR.
As far as the Spec and the Java class they look fine to me.
Mark
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic