Re: Using XMLNAMESPACES with XMLEMENT

2021-09-24 Thread Pavel Stehule
Hi pá 24. 9. 2021 v 23:44 odesílatel Garfield Lewis napsal: > Hi All, > > > > I am attempting to port the following statement from DB2z to Postgres: > > > > SELECT e.empno, e.firstnme, e.lastname, > > XMLELEMENT ( NAME "foo:Emp", > > XMLNAMESPACES('http://www.foo.com' AS "f

Re: Frequetly updated partial index leads to bloat on index for Postresql 11

2021-09-24 Thread Peter Geoghegan
> On Thu, Mar 18, 2021 at 6:51 AM Tom Dearman wrote: > Is this a known issue, are they any ways around it, and if it is an > issue is there a plan to fix it if a fix is possible? On second thought I do think that the improvements to 14 will fix this for you. See the test case here: https://www.p

Re: Using XMLNAMESPACES with XMLEMENT

2021-09-24 Thread Rob Sargent
> On Sep 24, 2021, at 4:54 PM, Garfield Lewis wrote: > >  > I’m using PG v12.6 and no I haven’t tried the path function. Do you have an > example? > > -- > Regards, > Garfield A. Lewis > > From: Rob Sargent > Date: Friday, September 24, 2021 at 6:52 PM > To: Garfield Lewis > Cc: "pgsql

Re: Using XMLNAMESPACES with XMLEMENT

2021-09-24 Thread Garfield Lewis
I’m using PG v12.6 and no I haven’t tried the path function. Do you have an example? -- Regards, Garfield A. Lewis From: Rob Sargent Date: Friday, September 24, 2021 at 6:52 PM To: Garfield Lewis Cc: "pgsql-gene...@postgresql.org" Subject: Re: Using XMLNAMESPACES with XMLEMENT On Sep 24,

Re: Using XMLNAMESPACES with XMLEMENT

2021-09-24 Thread Rob Sargent
> On Sep 24, 2021, at 3:44 PM, Garfield Lewis wrote: > >  > Hi All, > > I am attempting to port the following statement from DB2z to Postgres: > > SELECT e.empno, e.firstnme, e.lastname, > XMLELEMENT ( NAME "foo:Emp", > XMLNAMESPACES('http://www.foo.com' AS "foo"), >

Using XMLNAMESPACES with XMLEMENT

2021-09-24 Thread Garfield Lewis
Hi All, I am attempting to port the following statement from DB2z to Postgres: SELECT e.empno, e.firstnme, e.lastname, XMLELEMENT ( NAME "foo:Emp", XMLNAMESPACES('http://www.foo.com' AS "foo"), XMLATTRIBUTES(e.empno as "serial"), e.

Re: Faster distinct query?

2021-09-24 Thread Israel Brewster
> On Sep 23, 2021, at 8:55 PM, Michael Lewis wrote: > > It’s only when I add in the AND data.channels=channels.channel that the query > time blows up to 5+ minutes. I personally don’t understand why there would be > such a large difference between the two queries - something wrong with my > in

RE: Get COUNT results from two different columns

2021-09-24 Thread Clive Swan
Hi David, Thanks for the advice much appreciated. It is the first time that I have encountered this requirement, so was a bit lost in the forest.. As I only want a single id and value (new – old), would it be more efficient to use a SUBTRACT rather than a UNION functions?? The UNION