Lisa -
Thanks for your post on UT for my questions regarding an Adobe XML file. The sample file in my original post only had a couple of records in it. In reality the real file will have something in the range of 1000-2000 records. The Illustrator file is a map displaying traffic counts for the various roadway sections. The idea was that we could automate the updating of the traffic count numbers if I could get the data into a fox table and then read them back into the Illustrator file. This would go something like this:
1. Export the existing text data from the original map using Illustrator's Export to XML routine.
2. Load the exported XML into a Fox table.
3. Run some fox routines to update the data
4. Export the Fox table to XML
5. Import the revised XML into the original Illustrator map.
The expected result is that the map would now show revised numbers for the traffic volumes on the streets. The sample file contains 2 map layers "Data Set 2006" and "Data Set 2006b". In practice I'm not certain if there would need to be multiple layers in the XML or if we would deal with 3 separate files. The VFP tables would be pretty simple. Something like
CREATE TABLE "Data Set 2006" (LOC_ID C(6), COUNTVOL N(6,1))
CREATE TABLE "Data Set 2006b" (LOC_ID C(6), COUNTVOL N(6,1))
would do it. The data in our test tables would look like:
LOC_ID COUNTVOL
_B43 999
_A28 30.2
LOC_ID COUNTVOL
_B43 777
_A28 15.3
Here's the sample data again.
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20001102//EN" "http://www.w3.org/TR/2000/CR-SVG-20001102/DTD/svg-20001102.dtd" [
<!ENTITY ns_graphs "http://ns.adobe.com/Graphs/1.0/">
<!ENTITY ns_vars "http://ns.adobe.com/Variables/1.0/">
<!ENTITY ns_imrep "http://ns.adobe.com/ImageReplacement/1.0/">
<!ENTITY ns_custom "http://ns.adobe.com/GenericCustomNamespace/1.0/">
<!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">
<!ENTITY ns_extend "http://ns.adobe.com/Extensibility/1.0/">
]>
<svg>
<variableSets xmlns="&ns_vars;">
<variableSet varSetName="binding1" locked="none">
<variables>
<variable category="&ns_flows;" varName="_B43" trait="textcontent"></variable>
<variable category="&ns_flows;" varName="_A28" trait="textcontent"></variable>
</variables>
<v:sampleDataSets xmlns="&ns_custom;" xmlns:v="&ns_vars;">
<v:sampleDataSet dataSetName="Data Set 2006">
<_B43> <p>999</p> </_B43>
<_A28> <p>30.2</p> </_A28>
</v:sampleDataSet>
<v:sampleDataSet dataSetName="Data Set 2006b">
<_B43> <p>777</p> </_B43>
<_A28> <p>15.3</p> </_A28>
</v:sampleDataSet>
</v:sampleDataSets>
</variableSet>
</variableSets>
</svg>
Thanks for your interest.
>First, XMLSpy's ability to handle complex XSDs has *many* bugs in it (don't ask me to list them, and IAC it will matter which version of XMLSpy you happen to have, but they all have some bugs).
>
>The fact that XMLSpy doesn't think this document is valid against Adobe's schema is, basically, meaningless. You may want to another validator when XMLSpy complains.
>
>Second, this document is well-formed, so whether it is valid against whatever version of Adobe's schema they put in its header is immaterial, from Fox's POV.
>
>Don, how would you like the result to look in the cursor? Basically, design the cursor you want as the target and show us a CREATE TABLE statement or something. From there, this is doable.
>
>José, personally I don't much care whether we use XMLTOCURSOR or XMLAdapter here. XMLTOCURSOR uses a simpler format, so I'd go for that, unless Don indicates that the documents are very large, in which case XMLAdapter is definitely a better choice.
>
>Don, you may want to post to me e-mail, I don't read here very much, but you will be welcome to re-post my solution on UT.
>
>>L<