How to output CDATA sections in XQuery

I use Saxon through XSLPalette.app.

Add this to the prolog of your XQuery program:

declare namespace saxon="http://saxon.sf.net/";
declare option saxon:output "cdata-section-elements=content";

That will transform

<content>Hello, I am <em>some</em>content!</content>

into

<something><![CDATA[Hello, I am <em>some</em>content!]]></something>