how to retrive xml data for using sql query?
Answers were Sorted based on User's Feedback
SELECT XMLELEMENT
("Emp", XMLELEMENT("name", e.fname ||' '|| e.lname),
XMLELEMENT ( "hiredate", e.hire))
AS "RESULT"
FROM employees e
WHERE employee_id > 200 ;
This query produces the following typical XML result:
RESULT
-----------------
<Emp>
<name>John Smith</name>
<hiredate>2000-05-24</hiredate>
</Emp>
<Emp>
<name>Mary Martin</name>
<hiredate>1996-02-01</hiredate>
</Emp>
| Is This Answer Correct ? | 13 Yes | 0 No |
Answer / ksonga
SET VERIFY OFF
SET ECHO OFF
SET PAGES 0
SET LONG 100000
SET lONGCHUNKSIZE 10000
SET LINESIZE 200
select dbms_xmlgen.getxml('select * from emp') from dual
| Is This Answer Correct ? | 7 Yes | 0 No |
pls explain connect by prior with example and its real time use
What is a recycle bin in oracle?
Who developed oracle & when?
13. Display the second to fifth characters in each client name.
select statement does not retrieve any records. what exception is raised?
What is an Oracle Instance?
why pl sql doesn't support retrieving multiple records
i can create a view with two columns from emp table,, later i need to add one more emp column to existing view.. what is query similarly add one more column to existing primary key constraint.. please give me the solutions
What is object data modeling?
How to execute a stored program unit?
What is an Integrity Constrains ?
How to store only time; not date and time?