Actually, I expect the function looks like xmlquery(xmlcontent,xquery) and
return the query result.
So xmlconcat(xml1,xml2) become a good example to study.
starting from gram.y, I try to make parser to call xmlquery,the following is
the result of diff:
diff gram.y c:\new_gram.y
< XMLPI XMLQUERY XMLROOT XMLSERIALIZE
> XMLPI XMLROOT XMLSERIALIZE
< | XMLQUERY '(' expr_list ')'
< $$ = makeXmlExpr(IS_XMLQUERY, NULL,
< | XMLQUERY
IS_XMLQUERY is added in primenodes.h
but the parser can not find xmlquery, the makeXmlExpr is not called at all.
2009/12/31 Robert Haas <robertmhaas(at)gmail(dot)com>
> On Thu, Dec 31, 2009 at 3:33 AM, fangfang liu <yisuoyanyu888(at)gmail(dot)com>
> > Hi - Does anyone know how to add a xml support function into postgresql?
> > I want to add a function named xmlquery into postgresql.
> > I modify gram.y by adding xmlquery relatedcode wherever other xml support
> > functions appear.
> > but the parser can not find xmlquery, the makeXmlExpr is not called at
> How about CREATE OR REPLACE FUNCTION xmlquery(...) ?
> If that doesn't meet your needs, you'll need to explain what you're
> trying to do - and probably provide a patch showing what you've tried
> so far.
In response to
pgsql-hackers by date
|Next:||From: Simon Riggs||Date: 2009-12-31 11:25:19|
|Subject: Re: Hot Standy introduced problem with query cancel
|Previous:||From: Simon Riggs||Date: 2009-12-31 11:10:35|
|Subject: Re: Cancelling idle in transaction state|