Date Formats in Dbms_Xmlquery.getXML [message #92592] |
Thu, 30 September 2004 07:44 |
kamal
Messages: 12 Registered: February 2002
|
Junior Member |
|
|
Hi,
I have a problem in the Dbms_Xmlquery.getXML as it is getting data for the date fields as '9/25/2004 0:0:0'.
I want the field data to be displayed as '09/25/2004 00:00:00'.
Please, any if you have answers / solutions are appreciated.
Thanks! :)
|
|
|
Re: Date Formats in Dbms_Xmlquery.getXML [message #92596 is a reply to message #92592] |
Sun, 03 October 2004 13:11 |
Magnar Johannessen
Messages: 12 Registered: February 2004
|
Junior Member |
|
|
A solution is to use to_char on the date field:
example:
declare
i VARCHAR2(100);
begin
i := 'select to_char(sysdate,' || '''' || 'DD/MM/YYYY HH.MI.SS' || '''' || ') now from dual';
dbms_output.put_line( dbms_xmlquery.getxml(i));
end;
Regards
mj
|
|
|