Re: [PERFORM] the XID question

2011-01-21 Thread Robert Haas
On Thu, Jan 20, 2011 at 12:04 PM, Kevin Grittner wrote: > "Charles.Hou" wrote: > >> my postgresql version is 8.1.3 > > Ouch!  That's getting pretty old; I hope it's not on Windows. > > http://wiki.postgresql.org/wiki/PostgreSQL_Release_Support_Policy > > http://www.postgresql.org/about/news.865 >

Re: [PERFORM] the XID question

2011-01-20 Thread Kevin Grittner
"Charles.Hou" wrote: > my postgresql version is 8.1.3 Ouch! That's getting pretty old; I hope it's not on Windows. http://wiki.postgresql.org/wiki/PostgreSQL_Release_Support_Policy http://www.postgresql.org/about/news.865 > you means the newer version has a virtual transaction ID. and >

Re: [PERFORM] the XID question

2011-01-20 Thread Charles.Hou
On 1月20日, 上午6時46分, g...@2ndquadrant.com (Greg Smith) wrote: > Kevin Grittner wrote: > > Or just test it in psql.  BEGIN, run your query, look at pg_locks. > > If an xid has been assigned, you'll see it there in the > > transactionid column.  You can easily satisfy yourself which > > statements grab

Re: [PERFORM] the XID question

2011-01-19 Thread Charles.Hou
On 1月19日, 下午10時39分, kevin.gritt...@wicourts.gov ("Kevin Grittner") wrote: > Filip Rembia*kowski wrote: > > 2011/1/19 Charles.Hou : > >> " select * from mybook" SQL command also increase the XID ? > > > Yes. Single SELECT is a transaction. Hence, it needs a transaction > > ID. > > No, not in recent

Re: [PERFORM] the XID question

2011-01-19 Thread Greg Smith
Kevin Grittner wrote: Or just test it in psql. BEGIN, run your query, look at pg_locks. If an xid has been assigned, you'll see it there in the transactionid column. You can easily satisfy yourself which statements grab an xid... That's a good way to double-check exactly what's happening, bu

Re: [PERFORM] the XID question

2011-01-19 Thread Kevin Grittner
Andres Freund wrote: > On Wednesday, January 19, 2011 07:06:58 PM Chris Browne wrote: >> A read-only transaction won't consume XIDs, but if you don't >> expressly declare it read-only, they're still liable to get >> eaten... > No. The Xid is generally only allocated at the first place a real > x

Re: [PERFORM] the XID question

2011-01-19 Thread Andres Freund
On Wednesday, January 19, 2011 07:06:58 PM Chris Browne wrote: > kevin.gritt...@wicourts.gov ("Kevin Grittner") writes: > > Filip Rembia*kowski wrote: > >> 2011/1/19 Charles.Hou : > >>> " select * from mybook" SQL command also increase the XID ? > >> > >> Yes. Single SELECT is a transaction. Hence

Re: [PERFORM] the XID question

2011-01-19 Thread Chris Browne
kevin.gritt...@wicourts.gov ("Kevin Grittner") writes: > Filip Rembia*kowski wrote: >> 2011/1/19 Charles.Hou : > >>> " select * from mybook" SQL command also increase the XID ? >> >> Yes. Single SELECT is a transaction. Hence, it needs a transaction >> ID. > > No, not in recent versions of Po

Re: [PERFORM] the XID question

2011-01-19 Thread Kevin Grittner
Filip Rembia*kowski wrote: > 2011/1/19 Charles.Hou : >> " select * from mybook" SQL command also increase the XID ? > > Yes. Single SELECT is a transaction. Hence, it needs a transaction > ID. No, not in recent versions of PostgreSQL. There's virtual transaction ID, too; which is all that's

Re: [PERFORM] the XID question

2011-01-19 Thread Filip Rembiałkowski
2011/1/19 Charles.Hou : > what's the definetion of XID? XID == "Transaction ID". > " select * from mybook" SQL command also increase the XID ? Yes. Single SELECT is a transaction. Hence, it needs a transaction ID. greets, Filip -- Sent via pgsql-performance mailing list (pgsql-performance@po

Re: [PERFORM] the XID question

2011-01-19 Thread Charles.Hou
On 1月19日, 下午5時19分, "Charles.Hou" wrote: > after i backdb->dropdb->restoredb and then vacuum analy+full -> vacuum > freeze > > the XID had been increased by 4 billion in two weeks...is it noraml? > > what's the definetion of XID? > > " select * from mybook" SQL command also increase the XID ? > > r