Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> how to change dynamically field name when using recordtype
Hi,
I want to change the field name of a recordtype dynamically to
compare two values. For Example.
TYPE Rec IS RECORD (name VARCHAR2(300),
Roll NUMBER);
FUNCTION isEqual (l_Student Rec,
ColumnName VARCHAR2, Value VARCHAR2) BEGIN IF 'l_Student'||Columnname = Value THEN RETURN TRUE; ELSE RETURN FALSE;
l_Student Rec;
BEGIN
l_Student.Name:='JOHN';
isEqual(l_student,'.Name','JOHN');
END;
I have already tried with Dynamic SQL . But didn't got any option to
do like this.
Help me out...
Thanks in Advance.
Basant
Received on Fri Feb 20 2004 - 07:37:18 CST
![]() |
![]() |