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 |
Can u make a synonym for deptno=10 only from emp table.
Is a rollback possible to any savepoint?
What is a cluster?
What is recycle bin in Oracle?
How to create a new view in oracle?
what are the disadvantages of hierarchial database over RDBMS?
How to convert characters to times in oracle?
What is connection pool in oracle?
How do we represent comments in oracle?
What is the difference between sharding and replication?
I have two tables : COuntry,city I want all the cities in each country.Question on Cross Join.
How to invoke the original export import utilities?