XML output File Format change
Hi experts,
I am currenty getting below output in my XML file and it is wrapped in message type MT_Test.
<?xml version="1.0" encoding="UTF-8"?>
<ns0:MT_Test xmlns:ns0="http://test.com/xi/T1/Data">
<Tests>
<schemaLocation>http://tempuri.org/TestSchema.xsd F:/documentation/MID/Release-Test/TestSchema.xsd</schemaLocation>
<Test>
<HeaderID>This is a string 1</HeaderID>
</Test>
</Tests>
</ns0:MT_Test>
and I want to change it to the below format.
<?xml version="1.0" ?>
<Tests xmlns="http://tempuri.org/TestSchema.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://tempuri.org/TestSchema.xsd F:/documentation/TEMP/Release-Test/TestSchema.xsd">
<Test HeaderID="RES-996-25885-527">
</Test>
</Tests>
Request you to give your inputs on how I can achieve this?
Hi ,
You need a java mapping to produce exactly the output you posted here.
I assume you r working with PI 7.1 here is the java mapping code.
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.Map;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import org.w3c.dom.Document;
import org.w3c.dom.NodeList;
import com.sap.aii.mapping.api.AbstractTransformation;
import com.sap.aii.mapping.api.StreamTransformationException;
import com.sap.aii.mapping.api.TransformationInput;
import com.sap.aii.mapping.api.TransformationOutput;
public class FormatXML extends AbstractTransformation{
public void execute(InputStream in, OutputStream out)
throws StreamTransformationException {
try{
// TODO Auto-generated method stub
DocumentBuilderFactory factory=DocumentBuilderFactory.newInstance();
DocumentBuilder builderel=factory.newDocumentBuilder();
/*input document in form of XML*/
Document docIn=builderel.parse(in);
NodeList l=null;
String schemaLocation="";
l=docIn.getElementsByTagName("schemaLocation");
if(l!=null)
schemaLocation=l.item(0).getTextContent();
schemaLocation=schemaLocation.replaceFirst("/MID/", "/TEMP/");
String outPut="<?xml version=\"1.0\" ?><Tests xmlns=\"http://tempuri.org/TestSchema.xsd\" " +
"xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" " +
"xsi:schemaLocation=\""+schemaLocation+"\">"
+"<Test HeaderID=\"RES-996-25885-527\">"
+"</Test></Tests>";
out.write(outPut.getBytes("UTF-8"));
catch(Exception e)
throw new StreamTransformationException(e.getCause().toString());
public void setParameter(Map arg0) {
// TODO Auto-generated method stub
public static void main(String[] args) {
// TODO Auto-generated method stub
try{
FormatXML genFormat=new FormatXML();
FileInputStream in=new FileInputStream("C:\\Apps\\sdn\\format.xml");
FileOutputStream out=new FileOutputStream("C:\\Apps\\sdn\\format1.xml");
genFormat.execute(in,out);
catch(Exception e)
e.printStackTrace();
public void transform(TransformationInput arg0, TransformationOutput arg1)
throws StreamTransformationException {
this.execute(arg0.getInputPayload().getInputStream(), arg1.getOutputPayload().getOutputStream());
If you are new to java mapping pls follow this http://www.****************/Tutorials/XI/Mapping/Index.htm
You need to install eclipse and java 1.5.0 for PI 7.1. You also need proper library files for PI 7.1 which you need to download from PI server. Please follow this link http://wiki.sdn.sap.com/wiki/display/XI/WheretogetthelibrariesforXI+development
Regards
Anupam
Similar Messages
-
The file should be in XML-BURSTING-FILE format.
I'm gettting an error when I try to upload my xml bursting control file for my oracle report that has an rtf template defined.
The error message says"The uploaded file MT_RAXINV.xml is invalid. The file should be in XML-BURSTING-FILE format."
and my code is as below:
<?xml version="1.0" encoding="UTF-8"?>
<xapi:requestset xmlns:xapi="http://xmlns.oracle.com/oxp/xapi" >
<xapi:globalData location="stream">
</xapi:globalData >
<xapi:request select="/ZRAXINV/LIST_G_ORDER_BY/G_ORDER_BY/LIST_G_INVOICE/G_INVOICE">
<xapi:delivery>
<xapi:email server="mailhost.microtune.com" port="25" from="[email protected]"
reply-to ="[email protected]" >
<! - filter=".//G_INVOICE[BILL_TO_EMAIL IS NOT NULL]"- >
<xapi:message id="${TRX_NUMBER}" to="[email protected]" cc="[email protected]" attachment="true"
subject="Microtune Inc - Receivables Statement for payment due from ${BILL_CUST_NAME}">
Please find attached Receivables Statement for payment due of ${TOTAL_AMOUNT_DUE}.
Regards,
The Receivables Team
Microtune Inc
</xapi:message>
</xapi:email>
<xapi:print id="printer_tune"
printer="ipp:\\congo\sunset" filter=".//G_INVOICE[BILL_TO_EMAIL=NULL]" copies="1" />
<xapi:filesystem output="\\astro\erp\Oracle\${TRX_NUMBER}.pdf"/>
<! - Add an id for this delivery method i.e. printer1 - >
</xapi:delivery>
<xapi:document output-type="pdf" delivery="printer_tune,${TRX_NUMBER}">
<! - Deliver to printer and email - >
<xapi:template type="rtf" location="xdo://SQLAR.ARInvoice.en.US/"?getSource=true" filter="">
<! - Specify template to be used for Receivables Statements- >
</xapi:document>
</xapi:request>
</xapi:requestset>
Any help would be much appreciated.
Thanks,
LeoThanks, for the update. Sorry I did not update this entry, I had actually figured that out but still my problem is that my email is sending without an attachment. I'm not getting any error and the email is sending fine but without the attachment.
<?xml version="1.0" encoding="UTF-8"?>
<xapi:requestset xmlns:xapi="http://xmlns.oracle.com/oxp/xapi">
<xapi:request select="/ZRAXINV/LIST_G_ORDER_BY/G_ORDER_BY/LIST_G_INVOICE/G_INVOICE">
<xapi:delivery>
<xapi:email server="mailhost.microtune.com" port="25" from="[email protected]" reply-to ="[email protected]">
<xapi:message id="${TRX_NUMBER}" to="[email protected]" cc="[email protected]" attachment="true"
subject="Microtune Inc - Receivables Statement for payment due from ${BILL_CUST_NAME}">
Please find attached Receivables Statement for payment due of ${TOTAL_AMOUNT_DUE}.
Regards,
The Receivables Team
Microtune Inc.
</xapi:message>
</xapi:email>
</xapi:delivery>
<xapi:document output="Invoice_${TRX_NUMBER}" output-type="pdf" delivery="${TRX_NUMBER}">
<xapi:template type="rtf" location="xdo://SQLAR.ZRAXINV.en.US/?getSource=true"></xapi:template>
</xapi:document>
</xapi:request>
</xapi:requestset> -
How to calculate number of data records in a XML output file
Hi,
After generating a XML output file from Oracle Reports, I want to calculate number of records in the XML file. Is it possible? Specifically, I want to calculate number of records for a group variable ( organization_id, which I use for bursting).
Thanks for the help.Thanks BIPuser. It is useful for me.
I can use this xsl function within the template. However, I'm also looking to print this in the concurrent request log file. So, outside of rtf template, id there any PL/SQL based XML functions I can use to count the number of records.
Thanks. -
Oracle script to extract SQL server data to XML/CSX file format
HI,
I have a requirement like-
Create an Oracle script to Extract data from SQL Server to XML/CSV file format in File server (Oracle Server and File Server are in different boxes).
Create an Oracle script to Retrieve data from the File Server, validate and load into the Oracle staging table
Create an Oracle script to Push data from Oracle Staging table to native SQL Server table
We may/may not be using the staging table
Could anyone please respond immediately as it is urgent ?
Thanks,
Inbamalaruser10594152 wrote:
HI,
I have a requirement like-
Create an Oracle script to Extract data from SQL Server to XML/CSV file format in File server (Oracle Server and File Server are in different boxes).
Create an Oracle script to Retrieve data from the File Server, validate and load into the Oracle staging table
Create an Oracle script to Push data from Oracle Staging table to native SQL Server table
We may/may not be using the staging table
Could anyone please respond immediately as it is urgent ?
Thanks,
Inbamalar
Urgent issues indicate a live/production system is having problems and a company is losing money, or customers are being prevented from using it.
For urgent issues you should raise your issue with Oracle Support using your customer support identifier.
The community forums are for non-urgent issues. To suggest such issues are urgent is considered rude, as the people who help here are volunteers with their own jobs to do, so demanding their time for your "urgent" issue is not appropriate. It also suggests that you think your issue is more important than other people's issues, so you are being rude to those people too. Your issue is no more important than anyone elses.
In relation to your question, you need to provide more information.
Please read: Re: 2. How do I ask a question on the forums?
When you refer to "SQL Server" are you referring to the Microsoft SQL Server product, or are you just referring to a physical server with your oracle database on it? -
Hi all,
Does somebody know what is the PDF output file format in Oracle EBS 11.5.10.2?
Is it PDF/X, PDF/E, PDF/UA, PDF/VT or something else?
Thanks and regards,
KarmitHi,
See this thread.
concurrent ouput to email
concurrent ouput to email
Regards,
Hussein -
I like to generate an XML output file using the PLSQL. Can any one help with an example (using EMPand DEPT). I tried the forum but seems confusing to me...
This is URGENT so please rush!Please refer to the following post:
page 0 security: authorization scheme not applied to other pages -
Format of weblogic.store.Admin "dump -deep" XML output file?
Does anyone know where I can find a detailed description of the format of the XML file created by using the "dump -deep" command within the Store Administration utility?
I ran into a problem with stuck messages in a SAF persistent store on WebLogic 10.3.2. After trying everything I could think of to get the messages moving, I resorted to recovering them from the persistent store file into XML files on the filesystem, purging them from the SAF, and then re-injecting them onto the appropriate topics. The message recovery was very straightworward with a simple utility to extract the XML for the messages from the file generated by the "dump" command in the weblogic.store.Admin Store Administration utility. (NOTE: You must use the "-deep" dump option to get the message XML.)
This process was hampered by the fact that the stuck messages were intended for more than one destination and I could not easily discern the intended destination for each. This information must be in the persistent store, but I do not know whether it is available in the "dump -deep" file.
Any insight into the dump file format would be appreciated. I could not find anything in the docs.
Thanks!
- HarryThere's no facility that I know of for interpreting the data in a store.Admin dump - which explains why there's no mention of such a thing in the docs. If you're using SAF agents, I think it may have been possible to boot the WL host server, and then use the WL JMS "message management" utilities to "export" the messages. If you still need help, I recommend opening a case with customer support - make sure to save the original backing store (.DAT files or tables with file stores).
Tom -
Hi Friends,
I am working in SAP Technical upgrade Project from 4.6C to SAP ECC 6.0. In 4.6c one Z program is there, the output of Z program is to generate output XML file in the application Server. We checked and downloaded that the output file is readable and the XML is valid.
When we run the same program in ECC 6.0. (after unicode check & changes done), the output xml file is generated and it is in unreadable form. (XML contains some machine characters). When we open the XML in Altova Spy, it shows the error XML is invalid. The erorr is 'character #x3F3C is grammatically unexpected'.
In 4.6c, they used the encoding <?xml version="1.0" encoding="ISO-8859-1" ?> . We changed the encoding to UTF-8 in ECC 6.0 since we are doing unicode conversion. (
<?xml version="1.0" encoding="UTF-8" ?> ). After this change also, the output file is not generated correctly. It is unreadable form. (Some Machine Characters).
Friends, What could be the problem ? . Can you help me to identify this problem.
Kind regards,
Jegathees P.I troubleshooted that, the reason is that conversion of X to C (Hexadecimal to C) in the ASSIGN statement is not working correctly in ECC 6.0. Then, we replaced the code with our custom Function Module to convert xstring to string. After this, we got the XML correctly, readable and well-formed XML.
-
Dear Gurus,
I am working on a scenario where vendor master is triggered from SAP-XI--FTP.
when i am posting the vendor master on FTP.. i am getting
the xml output with prefix as below
<ns0:VENDORID>0000100000</ns0:VENDORID>at each element in vendor master xml file.
Instead of <VENDORID>0000100000</VENDORID>
could anyone tell how to fix this prefix at each level.
Does i need to add any module in file receiver adapter..or any patch i need to apply ..
we are on SP9 PI 7.0
Kind Regards,
VijayHi,
I tryed as per blog earlier ..it is not working
i am using file receiver adapter...any other solution to fix this.
Regards,
Vijay -
How to Generate XML Output file
Hi,
I want to print sample output XML file.
I got this link 362496.1
An output file can be generated via the Preview functionality available under the XML Publisher Administrator responsibility. Navigation path :
1. Login to the application as SYSADMIN
2. Responsibility: XML Publisher Administrator
3. Function: Templates
4. Select a Template for which a Preview Data file has been uploaded in the past.
5. Click on the Preview icon
6. Save the PDF to the client PC
7. Determine the version either by the above instructions OR by provide the PDF file to Global Customer Support.But in #4 I can not populate any values to search, even if I put all %.
How can I get a valid search?
Thanks a lot,
Ms KHi;
AFAIK if you prepare template in XML publisher than you can take output as pdf, by the way you can take xml output too
Please check user guide:
http://www.oracle.com/technology/products/xml-publisher/docs/XMLP5.6.1UserGuide.pdf
Oracle XML Publisher and Oracle Reports
Oracle XML Publisher and Oracle Reports
Also Please check below thread:
XML output for pdf concurrent program
http://www.quovera.com/whitepapers/downloads/xml_oracle.pdf
Generate XML output using DBMS_XMLGEN.getxmltype and not from rdf
http://www.orafaq.com/forum/t/35204/2/
Hope it helps
Regard
Helios -
UTL FILE OUTPUT FILE FORMAT ISSUE ON ORACLE 11G
how to format util file output align with column value with proper format.
set serveroutput on
DECLARE
CURSOR h1
IS
select 'TOTAL_ACCOUNT_REJECTS' as TOTAL_ACCOUNT_REJECTS ,
'PC' as PC ,
'RT' as RT,
'SERIAL' as SERIAL
from dual;
-- l_app_nm := RTRIM( TRIM( l_line ), CHR(13) );
CURSOR c1
IS
SELECT
company ,
user,
app,
account
FROM account_auth
WHERE ROWNUM < = 5;
lc_file_handle UTL_FILE.file_type;
lc_file_dir VARCHAR2 (100);
lc_file_name VARCHAR2 (50);
gov_005_payment_rec VARCHAR2 (1000);
BEGIN
lc_file_dir := 'OUTB';
lc_file_name := 'test.txt';
lc_file_handle := UTL_FILE.fopen (lc_file_dir, lc_file_name, 'W',1024);
FOR i IN h1
LOOP
gov_005_payment_rec :=
i.TOTAL_ACCOUNT_REJECTS
||' '
|| i.PC
|| ' '
|| i.RT
|| ' '
|| i.SERIAL;
UTL_FILE.put_line (lc_file_handle, gov_005_payment_rec);
END LOOP;
FOR i IN c1
LOOP
gov_005_payment_rec :=
i.company
||' '
|| i.user
||' '
|| i.app
||' '
|| i.account;
UTL_FILE.put_line (lc_file_handle, gov_005_payment_rec);
END LOOP;
EXCEPTION
WHEN UTL_FILE.INVALID_PATH THEN DBMS_OUTPUT.PUT_LINE('Invalid
path!');
WHEN UTL_FILE.INVALID_MODE THEN DBMS_OUTPUT.PUT_LINE('Invalid
mode!');
WHEN UTL_FILE.INVALID_OPERATION THEN DBMS_OUTPUT.PUT_LINE('Invalid
operation!');
WHEN OTHERS
RAISE;
END ;
OUTPUT : issue with file format
TOTAL_ACCOUNT_REJECTS PC RT SERIAL
&&&&&846 000000000000 APPLICATION123 20570
&&&&284 000000000000 APPLICATION133 20570
&&&2&&846 000000000000 APPLICATION163 20570
EXPECTED output ==> please advise me , how to create proper formatted output file using utl_file? thanks in advance.
TOTAL_ACCOUNT_REJECTS PC RT SERIAL
&&&&&846 000000000000 APPLICATION123 20570
&&&&284 000000000000 APPLICATION133 20570
&&&2&&846 000000000000 APPLICATION163 20570Example of creating a fixed width format file for a dynamically provided query, using the DBMS_SQL package...
As SYS user:
CREATE OR REPLACE DIRECTORY TEST_DIR AS '\tmp\myfiles'
GRANT READ, WRITE ON DIRECTORY TEST_DIR TO myuser
As myuser:
CREATE OR REPLACE PROCEDURE run_query(p_sql IN VARCHAR2
,p_dir IN VARCHAR2
,p_header_file IN VARCHAR2
,p_data_file IN VARCHAR2 := NULL) IS
v_finaltxt VARCHAR2(4000);
v_v_val VARCHAR2(4000);
v_n_val NUMBER;
v_d_val DATE;
v_ret NUMBER;
c NUMBER;
d NUMBER;
col_cnt INTEGER;
f BOOLEAN;
rec_tab DBMS_SQL.DESC_TAB;
col_num NUMBER;
v_fh UTL_FILE.FILE_TYPE;
v_samefile BOOLEAN := (NVL(p_data_file,p_header_file) = p_header_file);
BEGIN
c := DBMS_SQL.OPEN_CURSOR;
DBMS_SQL.PARSE(c, p_sql, DBMS_SQL.NATIVE);
d := DBMS_SQL.EXECUTE(c);
DBMS_SQL.DESCRIBE_COLUMNS(c, col_cnt, rec_tab);
FOR j in 1..col_cnt
LOOP
CASE rec_tab(j).col_type
WHEN 1 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
WHEN 2 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_n_val);
WHEN 12 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_d_val);
ELSE
DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
END CASE;
END LOOP;
-- This part outputs the HEADER
v_fh := UTL_FILE.FOPEN(upper(p_dir),p_header_file,'w',32767);
FOR j in 1..col_cnt
LOOP
CASE rec_tab(j).col_type
WHEN 1 THEN v_finaltxt := v_finaltxt||rpad(lower(rec_tab(j).col_name),rec_tab(j).col_max_len,' ');
WHEN 2 THEN v_finaltxt := v_finaltxt||rpad(lower(rec_tab(j).col_name),rec_tab(j).col_max_len,' ');
WHEN 12 THEN v_finaltxt := v_finaltxt||rpad(lower(rec_tab(j).col_name),greatest(19,length(rec_tab(j).col_name)),' ');
END CASE;
END LOOP;
UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
IF NOT v_samefile THEN
UTL_FILE.FCLOSE(v_fh);
END IF;
-- This part outputs the DATA
IF NOT v_samefile THEN
v_fh := UTL_FILE.FOPEN(upper(p_dir),p_data_file,'w',32767);
END IF;
LOOP
v_ret := DBMS_SQL.FETCH_ROWS(c);
EXIT WHEN v_ret = 0;
v_finaltxt := NULL;
FOR j in 1..col_cnt
LOOP
CASE rec_tab(j).col_type
WHEN 1 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
v_finaltxt := v_finaltxt||rpad(nvl(v_v_val,' '),rec_tab(j).col_max_len,' ');
WHEN 2 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_n_val);
v_finaltxt := v_finaltxt||rpad(nvl(to_char(v_n_val,'fm99999999999999999999999999999999999999'),' '),rec_tab(j).col_max_len,' ');
WHEN 12 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_d_val);
v_finaltxt := v_finaltxt||rpad(nvl(to_char(v_d_val,'DD/MM/YYYY HH24:MI:SS'),' '),greatest(19,length(rec_tab(j).col_name)),' ');
END CASE;
END LOOP;
UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
END LOOP;
UTL_FILE.FCLOSE(v_fh);
DBMS_SQL.CLOSE_CURSOR(c);
END;
This allows for the header row and the data to be written to seperate files if required.
e.g.
SQL> exec run_query('select * from emp','TEST_DIR','output.txt');
PL/SQL procedure successfully completed.
Output.csv file contains:
empno ename job mgr hiredate sal comm deptno
7369 SMITH CLERK 7902 17/12/1980 00:00:00800 20
7499 ALLEN SALESMAN 7698 20/02/1981 00:00:001600 300 30
7521 WARD SALESMAN 7698 22/02/1981 00:00:001250 500 30
7566 JONES MANAGER 7839 02/04/1981 00:00:002975 20
7654 MARTIN SALESMAN 7698 28/09/1981 00:00:001250 1400 30
7698 BLAKE MANAGER 7839 01/05/1981 00:00:002850 30
7782 CLARK MANAGER 7839 09/06/1981 00:00:002450 10
7788 SCOTT ANALYST 7566 19/04/1987 00:00:003000 20
7839 KING PRESIDENT 17/11/1981 00:00:005000 10
7844 TURNER SALESMAN 7698 08/09/1981 00:00:001500 0 30
7876 ADAMS CLERK 7788 23/05/1987 00:00:001100 20
7900 JAMES CLERK 7698 03/12/1981 00:00:00950 30
7902 FORD ANALYST 7566 03/12/1981 00:00:003000 20
7934 MILLER CLERK 7782 23/01/1982 00:00:001300 10
The procedure allows for the header and data to go to seperate files if required. Just specifying the "header" filename will put the header and data in the one file.
Adapt to output different datatypes and styles are required (this is currently coded for VARCHAR2, NUMBER and DATE) -
Ns0 in all the element tag of the XML output file
Hi Gurus,
I'm performing a mapping in the Integration Builder. The target structure is based on an imported xsd file via External Definitions.
However, in the output file, I'm getting a ns0 prefix in all the name of the elements.
Below is an example of how the output file looks like.
<ns0:Document xmlns:ns0="urn:iso:std:iso:20022:tech:xsd:pain.001.001.02">
<ns0:pain.001.001.02>
<ns0:GrpHdr>
<ns0:MsgId>0000000000247040099700</ns0:MsgId>
<ns0:CreDtTm>29-07-2008 16 44 06</ns0:CreDtTm>
<ns0:Authstn />
<ns0:BtchBookg>M</ns0:BtchBookg>
<ns0:NbOfTxs>1</ns0:NbOfTxs>
<ns0:Grpg>GRPD</ns0:Grpg>
Is there any way to get rid of the ns0? Issit some namespace definition which i need to specify somewhere?
Thanks in advance.Hi,
It does not matter whether your namespace prefix is ns, ns0, xyz or whatever.
When your mapping doesn't work there must be another reason.
Just try and paste the payload from moni and test ur mapping.
The namespace prefic ns0 is only a placeholder for the namespace urn:iso:std:iso:20022:tech:xsd:pain.001.001.02. This namespace can also be represented by another prefix or even by the empty prefix.
However, it is not possible to model the target payload via a Message type in the Integration Repository.
Message types are simply not suitable to model a document as you have posted. However, there is simple help. Just download the schema for the Message type to your local file system. Add attribute elementFormDefault="qualified" to the root tag of that schema. Upload that schema as External Definition. This External Definition will have one External Message. Define your mapping using that schema.
Thanks
Swarup -
*****output File format
Hi all,
Instead of Time stamp in the out put file ,we require the out put file format as xyz_a.txt,xyz_b.txt.......
eg:file name sample.txt out put required is sample_a,sample_b,sample_c......
is it possible in Xi?
Thanks,
SrinivasaHi,
Yes, you need to use variable substitution
http://help.sap.com/saphelp_nwpi71/helpdata/en/44/6a316af5a23672e10000000a114a6b/frameset.htm
Filename : sample_%var%.txt
Keep the mode as Create
The value of Var will be made a, b, or c in message mapping.
also if you want to name the target file as the one which you have read you can make use of Dynamic configuration, as mentioned here (See adapter specific identifiers)
http://help.sap.com/saphelp_nwpi71/helpdata/en/44/69d7cfa4b633eae10000000a1553f6/content.htm
Regards
Suraj
Edited by: S.R.Suraj on Oct 7, 2009 4:55 AM -
Adhoc Query- problem with the output file format
Hi Gurus,
I have a problem in exporting the output of an adhoc query to Excel format.
The menu option I chose to export the report data into Excel is List>Export>Spreadsheet.
However,I think I've just pressed the wrong option to export my report and now I can't seem to change it from a HTML file option.
Can anybody help me correct this output setting.
Points assured for apt help...Hi Sushil,
There are two ways to save the output in the excel format.
As you have mentioned, you can use
List -> Export-> Spreadsheet.
Then select table. Now the output will open in a spreadsheet.
The other way is
List -> Export-> Local File
Here you need to select the option spreadsheet. Then mention the path where you want the file to be stored. Also mention the format as .xls
Hope this helps
Regards,
Brinda -
XML output file with Control M Characters
Hi,
I am using JDOM API 1.0 on Solaris platform.
Using the XMLOuputter I write the XML data to a file. But the XML file contains Control-M characters at the end of each line..like
<User>^M
<Name>Satish</Name>^M
<id>12567</id>^M
</User>^M
File f = new File(path,Constants.USER_XML);
Document doc = getDocument();
XMLOutputter out = new XMLOutputter();
out.setFormat(Format.getPrettyFormat());
Format outFormat = out.getFormat();
outFormat.setLineSeparator(System.getProperty("line.separator"));
outFormat.setIndent(" ");
try{
FileWriter fw = new FileWriter(f);
out.output(doc,fw);
} catch(IOException iox) {}I am not writing the Control-M characters. Also I am using the default encoding which is UTF-8. So how to avoid the control characters. Thanks in advance.
Regards,
SatishThose are carriage-return (CR) characters. I don't know anything about the classes you are using but I would suggest you let the software decide what line endings it is going to use (the XML default is line-feed (LF) only) instead of telling it. Just a guess.
It's also possible that those CRs were in your input document and you are just copying them to the output document. XML parsers are supposed to normalize those characters to only LF but perhaps your parser isn't doing that. Just another guess.
Maybe you are looking for
-
How do I transfer my iTunes music library to a flash drive
How do I transfer my iTunes music library to a flash drive
-
Hi All, How to handle erroneous records in PSA. Should I consult R/3 consultants to correct them...
-
Macbook Pro Retina 15' (early 2013) / Creaking noise and hinge loose
Hi, After a couple of months of using my Macbook Pro Retina 15' (early 2013) started to creak when closing and opening. At first it wasn't loud but now, when im not using it for couple of hours and then try to open it creaks really bad. Also i've not
-
hello experts, please help me with this. i have a dynamic table and my output should be in a report format (write:). how can i WRITE the output using the dynamic table? and another thing, i should write the heading or the column names also... for exa
-
How to send an iPod to get refurbished?
I dropped my iPod touch 4th generation flat on the pavement. The screen is completely shattered and I want to send it back to Apple to get it refurbished. I have a 1 year warrrenty on it as well. How do I send it in?