Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries [Thread Prev] >Thread Next - Re: Simple Access Question Simple Access QuestionTo: NULL Date: 7/1/2004 10:10:00 AM I have a simple question (I think). I have 2 tables - states and
employees, and I want a breakdown of cities in those states in this
form. With the city as a child of the state - I'm new to XML so please
excuse it's innacuracy as I know it's not correct.
<StateCity>
<state_code>AK
<city>Anchorage</city>
<city>Cantwell</city>
<city>Cooper Landing</city>
</state_code>
</StateCity>
When I export the results from my query
SELECT
STATELIST.state_code, EMPLOYEE.city
FROM
STATELIST
INNER JOIN EMPLOYEE ON STATELIST.state_code = EMPLOYEE.state
GROUP BY
STATELIST.state_code, EMPLOYEE.city
ORDER BY
STATELIST.state_code, EMPLOYEE.city;
the XML comes out like this.
<StateCity>
<state_code>AK</state_code>
<city>Anchorage</city>
</StateCity>
<StateCity>
<state_code>AK</state_code>
<city>Cantwell</city>
</StateCity>
<StateCity>
<state_code>AK</state_code>
<city>Cooper Landing</city>
</StateCity>
Anyone know how to show the relationship in the export?
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
