[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] auto table mapping
The context is our storing a report-writer output into a standalone document so the same engine can later reparse the document, and allow user editing. We have a tree of report-writer objects, almost all of which link to one or more database views. An obvious shortcut is to put a lot of specialist attributes into our DTD so that our structures are easily rebuilt. I'm playing with the idea of having our parser able to recreate such a tree in a fairly generic manner (ie: handle other people's XML :-). The essential issue is the flattening of the bottom level. Instead of a general tree, with leaves containing PCDATA (or b64-encoded images) we want to recognise the situation where a number of sibling leaves are actually fields in a single record. Thus, two levels of the tree map to an internal 'table' object. Nested elements which contain other PCDATA leaves would be modelled as related tables (as an OORDBMS OOFILE models relationships as well as tables). The key assumptions here are 1) we will auto-generate some internal ID to track the relationships (I haven't time for the complexities of XML-Data, and join keys may not be in the exported data) 2) some portion of the DTD will fall into a pattern of 'tables' with possible nested tables 3) inside this pattern, we may require you to explicitly bracket multiple occurrences of an element inside another element so we can recognise a nested table (ie: <student> can't contain multiple <grade> elements directly, but needs <student> <results> <grade>) Is there interest in discussing this further or should I just carry on and implement something merely good enough for our immediate load/save operation? Andy Dent BSc MACS AACM, Software Designer, A.D. Software, Western Australia OOFILE - Database, Reports, Graphs, GUI for c++ on Mac, Unix & Windows PP2MFC - PowerPlant->MFC portability http://www.highway1.com.au/adsoftware/crossplatform.html xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@i... Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ To (un)subscribe, mailto:majordomo@i... the following message; (un)subscribe xml-dev To subscribe to the digests, mailto:majordomo@i... the following message; subscribe xml-dev-digest List coordinator, Henry Rzepa (mailto:rzepa@i...)
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|