to_xml and 3 levels of association?

Hi,

I successfully generated an XML file based on two table levels: