Home » Developer & Programmer » Forms » record group with concatination (dev 6i, 10g)
record group with concatination [message #414901] Fri, 24 July 2009 00:04 Go to next message
annu-agi
Messages: 238
Registered: July 2005
Location: Karachi
Senior Member

dear experts

I have a problem with creating record group where where clause
i m tring to make a record group with the following query
Create_Group_From_Query ( rg_name1,
'
select event_occurance_heading||' / '||event_occurance_type, to_char(event_occurance_id) from event_occurance_mst
'
); 



I know the problem is with ||' / '|| part of the query. kindly see what i am doing mistake here .


regards


Anwer
Re: record group with concatination [message #414911 is a reply to message #414901] Fri, 24 July 2009 00:26 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
And what IS the problem? What message are you receiving when you use this 'select' statement?

David
Re: record group with concatination [message #414913 is a reply to message #414911] Fri, 24 July 2009 00:41 Go to previous messageGo to next message
annu-agi
Messages: 238
Registered: July 2005
Location: Karachi
Senior Member

error is

frm- 40735 when new form instace trigger raised unhandle exception ora-06502
Re: record group with concatination [message #414914 is a reply to message #414913] Fri, 24 July 2009 00:51 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Oracle
ORA-06502 PL/SQL: numeric or value error string

Cause: An arithmetic, numeric, string, conversion, or constraint error occurred. For example, this error occurs if an attempt is made to assign the value NULL to a variable declared NOT NULL, or if an attempt is made to assign an integer larger than 99 to a variable declared NUMBER(2).

Action: Change the data, how it is manipulated, or how it is declared so that values do not violate constraints.

What datatypes are you concatenating? What is the target item's datatype? Is it (the item) large enough?
Re: record group with concatination [message #414932 is a reply to message #414914] Fri, 24 July 2009 01:42 Go to previous messageGo to next message
annu-agi
Messages: 238
Registered: July 2005
Location: Karachi
Senior Member

the declaring section is

declare
  rg_name1  VARCHAR2(400) := 'occurance_group'; 
  rg_id1    RecordGroup; 
  errcode1  NUMBER; 
  It_Id1    Item;

and the excution section is
begin
  rg_id1 := Find_Group(rg_name1); 
  IF Id_Null(rg_id1) THEN 
		rg_id1 := Create_Group_From_Query ( rg_name1,'select event_occurance_heading||'/'||event_occurance_type, to_char(event_occurance_id) from event_occurance_mst'); 
	End if;
  errcode1 := Populate_Group( rg_id1 );
  It_Id1 := find_item('event_mst.event_occurance_type');
  Populate_List(It_Id1,rg_id1);
end;


now see the output of sql is in attached file and also i converted already the numaric feild in charector


regards


Re: record group with concatination [message #415024 is a reply to message #414901] Fri, 24 July 2009 07:41 Go to previous message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
try doubling the quotes around the /
Previous Topic: problem in trigget
Next Topic: Execute Query with Non database Block
Goto Forum:
  


Current Time: Fri Sep 20 09:25:44 CDT 2024