I have two XSD files (source and target)... on what basis should I map these two files to get an XSLT? I know how MapForce helps in mapping but I worked with the sample project ..Now I wanted to know on what basis should I map these file that my client sent me..
I don't think there could be any general way to generate an XSLT given two XSD (if this is what your are after). The XSDs describe the structure of the XML files, but they don't say anything about what is the data they contain (their semantics if you will).
E.g.
<Customer>
<Name>ACME</Name>
<Address>9 Main Street, Anytown, USA</Address>
</Customer>
and
<Customer Name="ACME" City="Anytown" Country="USA" Address="9 Main Street"/>
are two XML describing more or less the same thing - but there is no way to know reading their XSD that the <Address> element in one correspond to three different attributes Address, City and Country in the other.
I am afraid you have to create the XSLT manually - and my suggestion would be to start from sample XML files, not the XSDs - much easier.
am afraid you have to create the XSLT manually - and my suggestion would be to start from sample XML files, not the XSDs - much easier.
Related
currently when working with mpxj library, generated task xml will have following attributes
<Task>
<UID>0</UID>
<ID>0</ID>
<Name>Naruto Uzumaki</Name>
<Active>1</Active>
<Manual>0</Manual>
......
......
</Task>
I do not want Active and Manual tags present in the generated xml, is there any way to achieve this? Kindly help.
Thanks in Advance.
I'm not sure of MS Project's behaviour if these values are removed entirely... if it would give you the defaults you are expecting when it reads the file. On that basis it is not something you can change in MPXJ itself.
However, one simple way to achieve what you want would be to apply an XSL transformation to the generated XML to remove the elements you don't want. The answer to this StackOverflow question provides an example of how this could be done.
Assuming you are using Java and you are writing to a stream you can probably use one of the mechanisms highlighted in this StackOverflow question to take the output directly from MPXJ and pass it through an XSL transformation.
I have a number of XSDs that are part of the enterprise definitions for several services at the client.
I would like to be able to take a single XSD and generate a DDIC structure from it (without the use of PI!)
Seeing as you can generate proxies directly from a WSDL, and this also generates structures and data elements from the XSD definitions inside the WSDL, there is obviously already ABAP code that does this.
But do you know what classes/function modules to use to achieve this? Perhaps there is a convenient utility function or class method that takes the XSD as input and generates the relevant DDIC objects?
Some background on why I need this:
Some of the services include variable sections that include a piece of XML containing the data for one of the enterprise XSD entities; I am hoping to have a DDIC representation of these, which I can fill at runtime and then convert to XML to include in the message.
There is a program on the system called SPROX_XSD2PROXY with which you can upload one or more XSD files which will generate proxy objects for you.
You also end up with a service consumer with a corresponding class and what looks like a dummy operation.
The program is fairly short; it uploads the files(s) to an XSTRING, then converts the XSD(s) to WSDL(s) and finally the WSDL(s) to proxy objects using methods of a class called CL_PROXY_TEST_UTILS.
However, the result is satisfactory as it does give me a structure I can work with. And by examining the contents of those methods, it may be possible to build a more fine-tuned tool if I need one.
i have the webage tvguide tvguideand i am having problem on how to start coding the xml for it just sample data
i can omit the advertising elements
XML Language should consist of:
a. XML Sample Data
b. DTD to define the sample data
c. Either an XML XSLT or and XSL-FO
d. CSS if you select XSLT
Your question is not very clear:
For generating xml from xsd you can use online tools like: http://xmlgrid.net/genXml.html
You can also use Eclipse, or any other IDE.
Why do you need DTD? XSD is like DTD only better.
XSLT helps transforming one XML to another, why do you need it?
How is CSS related?
So I have a XML file that contains a lot of data. My task is to extract the 'name' and 'description' information from the XML file so it reads out. I have been messing with it for a while, and I got half way there.
The way the data that I need to extract in the XML file looks like is
<name> Some Name</name>
and the data that is in the description is
<description> The Description </description>
What I have done is extract all the description to a text file, but I know I am doing this the hard/not efficient way. Any ideas?
Also, if I could add some detail to help describe what I am doing, I can do so! Hopefully I described it efficiently though.
Based on comments in question, create a C# application which uses XPath to extract the nodes you are interested in.
A good tutorial to follow:
http://support.microsoft.com/kb/308333
I am trying to generate a schema from this xml file:
http://eutils.ncbi.nlm.nih.gov/entrez/eutils/efetch.fcgi?rettype=xml&retmode=xml&db=nucleotide&id=AB573763
I store it as s.xml and then tried:
xsd s.xml
It just does not finish it - seems to be stuck in an endless loop or something. What other options do I have to generate the xsd or can you see something wrong?
Thanks.
Christian
A schema generated from a single instance document is never going to be as high quality as one created from a schema as you can be almost certain that the generated schema will have distinct limitations.
I would suggest that you download the schema from the NIH (http://www.ncbi.nlm.nih.gov/dtd/NCBI_Seqset.dtd as #Tuomas Hietanen showed) and use a tool such as James Clark's Trang to generate a schema. Your resulting schema is likely to be of higher quality. If you have a copy of Oxygen you can simply use that as Trang is built-in.
On the fly, this site do the job :
http://www.freeformatter.com/xsd-generator.html