ABAP Simple Transformation - How to save XML to file with CL_FX_WRITER?
Hello!
When calling a Simple Transformation program for transformation from ABAP to XML, it is possible to specify RESULT XML rxml as a class reference variable of type CL_FX_WRITER, which points to an XML writer.
How to handle CL_FX_WRITER in order to save XML to a file?
Thanks and regards,
Andrey
Hallo Rainer!
Many thanks. I have checked the profile parameter ztta/max_memreq_MB and it is set to 2048 MB in the development system. I hope, that won't be less on the client's machine. The only thing I did not clearly explained, is that I need to write XML data to the server. I am so sorry. Downloading to the local PC is very helpful for me also, but only for the test purposes.
Regards,
Andrey
Similar Messages
-
How to save as AI file with PDF compatability at the same location?
Hi Guys,
Requesting for script. Here are the details..
I do have lot of AI files (from different paths) which are do not have PDF compatability switch on. So now I am looking for script that all the files should save as at the same place (over write) and should switch on the PDF compatability switch on.
I tried with Action script, But the problem is, action scripting is recording the path where I saved first time. That means, all the files are save as into recorded path. This makes me some what confusion, because source file will be 1 and save file with PDF 1. So in total 2 files will create which is not good.
So I am requesting you that script schould overwirte at the same path and should switch on the PDF compatability.
FYI: Using Adobe CS4...
If you help for this, it is really greatful for me.
Thanks in advance...
Regards
HARI#target illustrator
var df = new Folder('~/Desktop');
var topLevel = Folder.selectDialog('Please choose your Top Level Folder…', df);
if (topLevel != null) {
topLevel = topLevel.fsName
var fileList = new Array();
fileListRecursive(topLevel, /\.ai$/i);
if (fileList.length > 0) {
main();
} else {
alert('This Folder or sub folders contained NO Illustrator AI files?');
function main() {
with (app) {
while (documents.length) {
activeDocument.close(SaveOptions.PROMPTTOSAVECHANGES);
//var orginalUIL = userInteractionLevel;
//userInteractionLevel = UserInteractionLevel.DONTDISPLAYALERTS;
for (var a = 0; a < fileList.length; a++) {
var docRef = open(fileList[a]);
with (docRef) {
var aiOptions = new IllustratorSaveOptions();
aiOptions.compatibility = Compatibility.ILLUSTRATOR12; // Change to 14 for CS4
aiOptions.compressed = true;
aiOptions.embedICCProfile = true;
aiOptions.embedLinkedFiles = false;
aiOptions.flattenOutput = OutputFlattening.PRESERVEAPPEARANCE;
aiOptions.fontSubsetThreshold = 0;
aiOptions.overprint = PDFOverprint.PRESERVEPDFOVERPRINT;
aiOptions.pdfCompatible = true;
aiFilePath = new File(fullName);
saveAs(aiFilePath, aiOptions);
close(SaveOptions.DONOTSAVECHANGES);
//userInteractionLevel = orginalUIL;
function fileListRecursive(f, exp) {
var t = Folder(f).getFiles();
for (var i = 0; i < t.length; i++) {
if (t[i] instanceof File && RegExp(exp).test(t[i].fsName)) fileList.push(t[i]);
if (t[i] instanceof Folder) fileListRecursive(t[i].fsName, exp);
} -
How to save a PSD file with a composite image?
Windows 7 64bit | Photoshop CS4 | iMatch DAM
Somewhere along the line I must have changed a setting, because many of my images now are not viewable in my DAM software (iMatch), or other photo viewers, like Picasa for instance. Instead, a small rectangular black box appears that says "This layered Photoshop file was not saved with a composite image". Can a contributor tell me where the setting is to save with a composite - Assistance is very much appreciated, IMThank you Chris,for the correct answer - Best, Bob
-
Simple Transformation to deserialize an XML file into ABAP data structures?
I'm attempting to write my first simple transformation to deserialize
an XML file into ABAP data structures and I have a few questions.
My simple transformation contains code like the following
<tt:transform xmlns:tt="http://www.sap.com/transformation-templates"
xmlns:pp="http://www.sap.com/abapxml/types/defined" >
<tt:type name="REPORT" line-type="?">
<tt:node name="COMPANY_ID" type="C" length="10" />
<tt:node name="JOB_ID" type="C" length="20" />
<tt:node name="TYPE_CSV" type="C" length="1" />
<tt:node name="TYPE_XLS" type="C" length="1" />
<tt:node name="TYPE_PDF" type="C" length="1" />
<tt:node name="IS_NEW" type="C" length="1" />
</tt:type>
<tt:root name="ROOT2" type="pp:REPORT" />
<QueryResponse>
<tt:loop ref="ROOT2" name="line">
<QueryResponseRow>
<CompanyID>
<tt:value ref="$line.COMPANY_ID" />
</CompanyID>
<JobID>
<tt:value ref="$line.JOB_ID" />
</JobID>
<ExportTypes>
<tt:loop>
<ExportType>
I don't know what to do here (see item 3, below)
</ExportType>
</tt:loop>
</ExportTypes>
<IsNew>
<tt:value ref="$line.IS_NEW"
map="val(' ') = xml('false'), val('X') = xml('true')" />
</IsNew>
</QueryResponseRow>
</tt:loop>
</QueryResponse>
</tt:loop>
1. In a DTD, an element can be designated as occurring zero or one
time, zero or more times, or one or more times. How do I write the
simple transformation to accommodate these possibilities?
2. In trying to accommodate the "zero or more times" case, I am trying
to use the <tt:loop> instruction. It occurs several layers deep in the
XML hierarchy, but at the top level of the ABAP table. The internal
table has a structure defined in the ABAP program, not in the data
dictionary. In the simple transformation, I used <tt:type> and
<tt:node> to define the structure of the internal table and then
tried to use <tt:loop ref="ROOT2" name="line"> around the subtree that
can occur zero or more times. But every variation I try seems to get
different errors. Can anyone supply a working example of this?
3. Among the fields in the internal table, I've defined three
one-character fields named TYPE_CSV, TYPE_XLS, and TYPE_PDF. In the
XML file, I expect zero to three elements of the form
<ExportType exporttype='csv' />
<ExportType exporttype='xls' />
<ExportType exporttype='pdf' />
I want to set field TYPE_CSV = 'X' if I find an ExportType element
with its exporttype attribute set to 'csv'. I want to set field
TYPE_XLS = 'X' if I find an ExportType element with its exporttype
attribute set to 'xls'. I want to set field TYPE_PDF = 'X' if I find
an ExportType element with its exporttype attribute set to 'pdf'. How
can I do that?
4. For an element that has a value like
<ErrorCode>123</ErrorCode>
in the simple transformation, the sequence
<ErrorCode> <tt:value ref="ROOT1.CODE" /> </ErrorCode>
seems to work just fine.
I have other situations where the XML reads
<IsNew value='true' />
I wanted to write
<IsNew>
<tt:value ref="$line.IS_NEW"
map="val(' ') = xml('false'), val('X') = xml('true')" />
</IsNew>
but I'm afraid that the <tt:value> fails to deal with the fact that in
the XML file the value is being passed as the value of an attribute
(named "value"), rather than the value of the element itself. How do
you handle this?Try this code below:
data l_xml_table2 type table of xml_line with header line.
W_filename - This is a Path.
if w_filename(02) = '
open dataset w_filename for output in binary mode.
if sy-subrc = 0.
l_xml_table2[] = l_xml_table[].
loop at l_xml_table2.
transfer l_xml_table2 to w_filename.
endloop.
endif.
close dataset w_filename.
else.
call method cl_gui_frontend_services=>gui_download
exporting
bin_filesize = l_xml_size
filename = w_filename
filetype = 'BIN'
changing
data_tab = l_xml_table
exceptions
others = 24.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif. -
How to save xml output of fm into sap as xml
how to save xml output of fm into sap as xml
thank you,
regards,
Jagrut bharatkumar shuklaHi Jagrut
The XML document can be stored in an ABAP variable rxml of the type STRING or XSTRING, or in an internal standard table sxml of the elementary line type C. Hence, I believe, your issue with the lenght can be resovled with this types.
For rxml, you specify an interface reference variable of the type IF_IXML_OSTREAM that points to an IXML output stream.
For rxml, you specify an interface reference variable of the type IF_IXML_DOCUMENT that points to an IXML document.
With the stream factory you have several options. Before you call your CALL TRANSFORMATION, you setup your stream factory for these different options.
1. You want to write the file to the application server file system. You want to create your OSTREAM as a binary string. In this example b_xml is an empty binary string. OSTEAM will be the reference variable of tyep IF_IXML_OSTREAM.
ostream =
streamfactory->create_ostream_xstring( b_xml ).
You get the output lenght with the following:
ressize = ostream->get_num_written_raw( ).
You can then send the entire string to the file system with the following:
transfer b_xml to filename1 length ressize.
Also refer to this weblog:
/people/tobias.trapp/blog/2005/05/04/xml-processing-in-abap-part-1
Regards
Ravish Garg
<b>
*Remember reward points is the best way to say thank you :)</b> -
Simple transformation error in converting XML to internal table
Hi Team,
I have an issue, its working in Dev, QA, and Prod in PI 7.0, once we upgrade it to PI 7.1 I'm getting the below mention error,
Unknown Simple transformation error in converting XML to internal table
Application error in mapping program ZF_INT006_FILE_TO_SAP_FILE, error code: , error text: Unknown Simple transformation error in converting XML to internal table An exception has occurred.
Can any one suggest related notes are suggestion.
appericate in advance for the solutions which you all provide me
Thank you
Venkat AnilCheck the flag "use SAP XML toolkit" for the operation mapping and try, if that works then.
Check the flag for all XSLT and Java mappings which is migrated from PI 7.0 -
Hi,
It is urgent for me to know how to save xml file. I use VC++6.0, Oracle xdk 9.0.0.0.0 or 9.0.0.0.0Abeta under windows98.
It is OK to compile the program with print() method. But system will tell me there is illegal operation when I run it. If I delete the line with print(), the result will be normal.
in class node, there is two functions
void print(ostream *out = &cout, uword level = 0,uword step = 4);
void print(DOMString buffer, size_t bufsize, uword level = 0, uword step = 4);
Is there anyone who may tell me how to use them? to write back specific xml file?
Without print(), I can not save the xml file...It seems in Oracle xdk9.0.0.0.0, there is no obvious function to save the file.(or because I am a new comer , not familier with DOM)
Can anyone tell me how to save xml file? or just paste an example! It is very a little urgent to me...Hope you give me some ideas....
Many thanks in advance!!!!
yours,
FienaHi,
goto sxmb_adm > intergration engine configration > specific configration
go in edit mode > new entry
choose
Category -> IDoc
Parameters -> XML_CONVERSION
current value -> 2
Regards,
Manisha -
Please can someone tell me how to save a MP3 file from my email on my iPad so I can put it on Faceboo? I use hotmail and please tell me step by step as I am not a tech guru lol. Thankyou
Hi jscher200,
Thank you for your reply, sorry for the VERY late late response, but I have just figured out how to control this separate 'panel'. I find it really useful for monitoring Google Analytics in as it can just sit there running. It does have its limitations, as it's a limited size (you can't expand it to full screen view), so you can only ever see a vertical section of a website and need to scroll to look to the right or left, but I have the live view of people accessing my website running on there and if the numbers start racking up at any time, I can scroll to look and see what pages they are accessing, where they've been referred from, etc.
To get it to work, you save a website address in the Bookmarks Toolbar and when you can see it sitting on the toolbar at the top of the screen with its little icon, right click on it then click 'properties', then tick the box 'Load this bookmark in the sidebar'. The next time you click on this bookmark to open the website, it will load in this sidebar, which looks like a separate 'window' but is immovable. You can only have one sidebar application running at a time, but can change it by right clicking on the bookmark you want to load in there and it will then change to that one next time you click on that bookmark.
I hope this might be useful to others, as I asked for help with this on loads of forums and not one person knew that this existed - even really skilled techies! -
How to save the report file in network drive
Hi experts,
Can any one of you pls tell me how can save the report file in network drive.
My requirement:
by running a report i wll get daily data into a list.SO, i want to keep this in a common drive (network drive:Z) where every one can acces the txt file.
I want the code in SAP to design this.
Awaiting for an early reply.Is the Z drive in the application or presentation server ?
make sure the server has write access to the required folder
for presentation server
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = 'c:\test_xls.xls'
filetype = 'ASC'
write_field_separator = 'X'
TABLES
data_tab = itab.
for the application server, use
data: outfile(120).
OPEN DATASET outfile FOR APPENDING IN TEXT MODE ENCODING DEFAULT. -
Can someone please tell me how to save a snapsnot taken with Adobe Reader X?
Could someone please tell me how to save a snapshot taken with Adobe Reader X ?
After taking the snapshot, you need to open a new document in an application that allows you to paste images.
-
How to save a numbers file to a pdf file of multiple pages instead of one giant long page?
How to save a numbers file to a pdf file of multiple pages instead of one giant long page?
Hi DW,
Numbers 3.2.2
Instead of Menu > File > Export To, use Menu > File > Print...
That takes you to Print Preview.
In the Print Setup panel, Click on the Print... button lower right (it won't print yet).
That opens the Print Dialogue.
Click on the PDF Pop-Up Menu lower left.
Choose Open PDF in Preview or Save as PDF.
That will have page breaks and will be full sized.
Print from Preview.
Regards,
Ian. -
How to create a pdf file with CS5
Hello, I'm new to PhotoShop CS5 and haven't figured out yet (despite two hours of trying) how to create a pdf file with pictures and texts. Can someone please help me with this ? The "help" button in CS5 doesn't seem to cover this question. Nor do the FAQs.
Thank you very much.Save As... Photoshop PDF.
-
Want attach the XML data file with layout template in Oracle 10g
Hi All,
I need a help from you genius guys.
I am genrating reports in BI with xml the procedure which I am following is as below.
1. generating XML from the RDF
2. creating a template in .rtf format
3.after that loading the xml to the template then getting the required report.
This all is doing through the given buttons
But now my requirement is to create the gui from user can select the report and get the desire output file so how we would be able to attach the XML data file with layout template in Oracle 10g.
If you require more detail please let me knnow.
Thanks,
HarryI am not using Oracle apps.
I am using oracle 10g reports and I get something in it like one patch I downloded and one java code is having which creates the batch file ...still I am working on it ..
If you will get some please share so that it will be helpful.
Thanks,
Harry -
How can I export a file with transparent background?
Hi all,
I know InDesign doesn't allow to export a PNG file, but I need my file to be in image file format with transparent background.
I'm still learning so I am stuck here. How can I export a file with transparent background?If you can't get the PNG file export to work, you can export a pdf and open it in Photoshop, from there you can save it as whatever you like.
-
How to load unicode data files with fixed records lengths?
Hi!
To load unicode data files with fixed records lengths (in terms of charachters and not of bytes!) using SQL*Loader manually, I found two ways:
Alternative 1: one record per row
SQL*Loader control file example (without POSITION, since POSITION always refers to bytes!)<br>
LOAD DATA
CHARACTERSET UTF8
LENGTH SEMANTICS CHAR
INFILE unicode.dat
INTO TABLE STG_UNICODE
TRUNCATE
A CHAR(2) ,
B CHAR(6) ,
C CHAR(2) ,
D CHAR(1) ,
E CHAR(4)
) Datafile:
001111112234444
01NormalDExZWEI
02ÄÜÖßêÊûÛxöööö
03ÄÜÖßêÊûÛxöööö
04üüüüüüÖÄxµôÔµ Alternative2: variable length records
LOAD DATA
CHARACTERSET UTF8
LENGTH SEMANTICS CHAR
INFILE unicode_var.dat "VAR 4"
INTO TABLE STG_UNICODE
TRUNCATE
A CHAR(2) ,
B CHAR(6) ,
C CHAR(2) ,
D CHAR(1) ,
E CHAR(4)
) Datafile:
001501NormalDExZWEI002702ÄÜÖßêÊûÛxöööö002604üuüüüüÖÄxµôÔµ Problems
Implementing these two alternatives in OWB, I encounter the following problems:
* How to specify LENGTH SEMANTICS CHAR?
* How to suppress the POSITION definition?
* How to define a flat file with variable length and how to specify the number of bytes containing the length definition?
Or is there another way that can be implemented using OWB?
Any help is appreciated!
Thanks,
Carsten.Hi Carsten
If you need to support the LENGTH SEMANTICS CHAR clause in an external table then one option is to use the unbound external table and capture the access parameters manually. To create an unbound external table you can skip the selection of a base file in the external table wizard. Then when the external table is edited you will get an Access Parameters tab where you can define the parameters. In 11gR2 the File to Oracle external table can also add this clause via an option.
Cheers
David
Maybe you are looking for
-
Missing Some Select input options the Query
Hello all, Normally when i excute a query, it will ask for date range and year, fiscal period etc input options which i have to input to execute a given query. But for one of the BWuser(sales guy) iam unable to see the fields, can anyone guess what
-
Please help me figure out how to get my 3rd generation ipod to have the newest software in order to download apps. It will not let me.
-
TAXINN - Base Value in Migo for the item is ZERO
Hi, We are using TAXINN Tax Procedure. In MIGO Excise Item Tab, Base value is coming zero. Also it is updating in Excise Registers 23A part I & 2. Can anybody tell me where i am doing a mistake. Thanks in advance KK
-
Does anyone know if iWeb 09 fixed the problem with Aperture generated MobileMe Photo Galleries not showing up when you want to insert a MobileMe Gallery widget on your web page? In iWeb 08 only iPhoto MobileMe Galleries showed up, which is a pain sin
-
Hi = Ihave severa; mv4 files that I would like to convery so that I can burn an audio CD for my car.Does any one know of anything (software) that does this for a mac? thanks