execute immediate issue - updated [message #36026] |
Tue, 30 October 2001 12:33 |
kshathrya
Messages: 29 Registered: October 2001
|
Junior Member |
|
|
can u tell me whats the issue here, please. The table name is not being picked by the execyte immediate
DECLARE
v NUMBER;
v_obj_name VARCHAR2 (40);
qry VARCHAR2 (100);
BEGIN
v_obj_name := 'MAN';
qry := 'SELECT COUNT(*) INTO '
|| v
|| ' FROM '
|| v_obj_name ;
EXECUTE IMMEDIATE qry;
DBMS_OUTPUT.put_line (v);
END;
----------------------------------------------------------------------
|
|
|
Re: execute immediate issue - updated [message #36027 is a reply to message #36026] |
Tue, 30 October 2001 13:34 |
Todd Barry
Messages: 4819 Registered: August 2001
|
Senior Member |
|
|
DECLARE
v NUMBER;
v_obj_name VARCHAR2 (40);
qry VARCHAR2 (100);
BEGIN
v_obj_name := 'MAN';
qry := 'SELECT COUNT(*) FROM ' || v_obj_name;
EXECUTE IMMEDIATE qry into v;
DBMS_OUTPUT.put_line (v);
END;
----------------------------------------------------------------------
|
|
|