|
[XQuery Talk Mailing List Archive Home] [By Date] [By Thread] [By Subject] [By Author] [Recent Entries] [Reply To This Message] ANSWERS to "What's wrong with XQuery" questionDave Pawson dave.pawson at gmail.comWed Jul 28 12:44:04 PDT 2010
On 28 July 2010 10:26, Andrew Welch <http://x-query.com/mailman/listinfo/talk> wrote:
> Here's another example, say you have a function to return to the HTML
> the xquery equivalent is:
>
> declare function f:getHead() {
> <title>some title</title>
> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
> };
>
> ...but that causes an error.... its missing a comma:
>
> declare function f:getHead() {
> <title>some title</title>,
> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
> };
>
That's exactly it Andrew.
I find it hard/odd to determine that I need a sequence (hence the comma).
Or more likely, when I'm generating a sequence.
The other infuriating one is when to drop in those {} pairs.
Face it, xquery is an 'odd' syntax that takes some getting used to,
more so when you step beyond simple tutorial class examples.
regards
--
Dave Pawson
XSLT XSL-FO FAQ.
Docbook FAQ.
http://www.dpawson.co.uk
|
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
|

Cart








