Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / July 2006

Tip: Looking for answers? Try searching our database.

XML file from one DTD to another DTD

Thread view: 
test - 28 Jul 2006 17:58 GMT
I need some help and advice with creating an XML file.

I have the following inputs: DTD 3.0 , DTD 4.0 and test.xml file that
is for DTD3.0

Task to accomplish     :Create a new test2.xml with the same values of
test.xml but
to validate against DTD 4.0.

Background about the DTDs: Both DTD 3.0 and DTD 4.0 are drastically
different.
There are parent child relationships that have been changed, new fields
introduced and old fields removed etc.

Feedback: Most important thing I want to know is can a tool accomplish
this( say Turbo xml etc)
       If not, is it possible for a program ( say java) or am I trying
something that can't be done.
Greg R. Broderick - 28 Jul 2006 19:20 GMT
> Task to accomplish       :Create a new test2.xml with the same values of
> test.xml but
> to validate against DTD 4.0.

<http://www.w3.org/Style/XSL/>

Cheers
GRB

Signature

---------------------------------------------------------------------
Greg R. Broderick            gregb.usenet200606@blackholio.dyndns.org

A. Top posters.
Q. What is the most annoying thing on Usenet?
---------------------------------------------------------------------

Oliver Wong - 28 Jul 2006 21:48 GMT
>I need some help and advice with creating an XML file.
>
[quoted text clipped - 14 lines]
>     If not, is it possible for a program ( say java) or am I trying
> something that can't be done.

   I don't think this can be done for any arbitrary pair of DTDs. Consider
the following pseudo DTDs:

[BEGIN firstPseudoDTD]
Root element is "Person".
Person has attribute "Age" (int), "Name" (String)
[END firstPseudoDTD]

[BEGIN secondPseudoDTD]
Root element is "Hamburger".
Hamburger has attribute "withKetchup" (boolean), "withMustard" (boolean)
[END secondPseudoDTD]

   How could you possibly convert an XML file complying with the first DTD
to the second one?

   - Oliver


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.