Re: [GENERAL] Help estimating database and WAL size

2012-10-12 Thread John R Pierce
On 10/08/12 1:39 PM, Daniel Serodio (lists) wrote: 3) Estimate the size of the transaction log ** We've got no idea how to estimate this, need advice ** postgres doesn't have a 'transaction log', it has the WAL (Write-Ahead Logs). These are typically 16MB each. on databases with a reall

Re: [GENERAL] Help estimating database and WAL size

2012-10-12 Thread Jasen Betts
On 2012-10-08, Daniel Serodio (lists) wrote: > We are preparing a PostgreSQL database for production usage and we need > to estimate the storage size for this database. We're a team of > developers with low expertise on database administration, so we are > doing research, reading manuals and us

Re: [GENERAL] Postgres DB Migration from 8.3 to 9.1

2012-10-12 Thread John R Pierce
On 10/12/12 9:52 PM, Vishalakshi Navaneethakrishnan wrote: While testing upgrade facility, I have installed postgres 9.2 using source package. Because it needs to be compiled with --disable-integer-datetimes. I have used this command ./configure --prefix=/opt/PostgreSQL/9.2/ --disable-integ

Re: [GENERAL] Postgres DB Migration from 8.3 to 9.1

2012-10-12 Thread Vishalakshi Navaneethakrishnan
Hi all, While testing upgrade facility, I have installed postgres 9.2 using source package. Because it needs to be compiled with --disable-integer-datetimes. I have used this command ./configure --prefix=/opt/PostgreSQL/9.2/ --disable-integer-datetimes --without-readline After installation i

Re: [GENERAL] tablespace_oid alias?

2012-10-12 Thread Tom Lane
Thalis Kalfigkopoulos writes: > Which would be the OID alias type for tablespace_oid? There is none. Use "select oid from pg_tablespace where spcname = 'whatever'". (In general, OID alias types only get invented for object types where the lookup rules are more complicated than that, eg where yo

Re: [GENERAL] Postgres DB Migration from 8.3 to 9.1

2012-10-12 Thread Scott Marlowe
On Thu, Oct 11, 2012 at 8:15 PM, Vishalakshi Navaneethakrishnan wrote: > Hi Friends, > > We have our production environment database server in Postgres 8.3 version. > we have planned to upgrade to lastest version 9.1. Dump from 8.3 and > restore in Postgres 9.1 takes more than 5 hours. Any other

[GENERAL] tablespace_oid alias?

2012-10-12 Thread Thalis Kalfigkopoulos
Hi all, I want to get the databases that correspond to a certain tablespace through a call to pg_tablespace_databases(tablespace_oid) Which would be the OID alias type for tablespace_oid? I've tried: # select pg_tablespace_databases('pg_default'::XXX); with XXΧ as any of the OID aliases mention

Re: [GENERAL] Limit+Offset query wrong result in Postgres 9.0.3 ?

2012-10-12 Thread Josh Kupershmidt
On Fri, Oct 12, 2012 at 3:33 AM, Alban Hertroys wrote: > On 12 October 2012 04:55, urkpostenardr wrote: >> Hi, >> >> Is this bug in Postgres ? >> If yes, is it fixed in latest release ? >> Second query should return 2 rows instead of 1 ? >> >> create table t(i int); >> insert into t values(1); >>

Re: [GENERAL] PostgreSQL and WMS

2012-10-12 Thread salah jubeh
yes , it is . i forget how to do it . you just need to a connection information in the wms configuration file From: José Pedro Santos To: Postgres Ajuda Sent: Friday, October 12, 2012 5:46 PM Subject: [GENERAL] PostgreSQL and WMS Dear all, I would like

Re: [GENERAL] Strategies/Best Practises Handling Large Tables

2012-10-12 Thread John R Pierce
On 10/12/12 7:44 AM, Chitra Creta wrote: 1. Purge old data 2. Reindex 3. Partition 4. Creation of daily, monthly, yearly summary tables that contains aggregated data specific to the statistics required if most of your queries read the majority of the tables, indexing will be of little hel

Re: [GENERAL] Postgres DB Migration from 8.3 to 9.1

2012-10-12 Thread Bruce Momjian
On Thu, Oct 11, 2012 at 07:38:07PM -0700, John R Pierce wrote: > On 10/11/12 7:15 PM, Vishalakshi Navaneethakrishnan wrote: > >We have our production environment database server in Postgres 8.3 > >version. we have planned to upgrade to lastest version 9.1. Dump > >from 8.3 and restore in Postgres

[GENERAL] PostgreSQL and WMS

2012-10-12 Thread José Pedro Santos
Dear all, I would like to know if is possible set up a service (WMS/WFS) for a layer stored within Postgres. I have one WEBGIS application that can't connect to PostgreSQL but if I use the data inside Postgres I can get the URL from WMS and add the maps. Best Regards, José Santos

Re: [GENERAL] Strategies/Best Practises Handling Large Tables

2012-10-12 Thread Ryan Kelly
On Sat, Oct 13, 2012 at 01:44:02AM +1100, Chitra Creta wrote: > Hi, > > I currently have a table that is growing very quickly - i.e 7 million > records in 5 days. This table acts as a placeholder for statistics, and > hence the records are merely inserted and never updated or deleted. > > Many qu

Re: [GENERAL] Postgres DB Migration from 8.3 to 9.1

2012-10-12 Thread Steve Crawford
On 10/12/2012 08:05 AM, Amitabh Kant wrote: On Fri, Oct 12, 2012 at 7:45 AM, Vishalakshi Navaneethakrishnan mailto:nvishalak...@sirahu.com>> wrote: Hi Friends, We have our production environment database server in Postgres 8.3 version. we have planned to upgrade to lastest version

Re: [GENERAL] Strategies/Best Practises Handling Large Tables

2012-10-12 Thread Ondrej Ivanič
Hi, On 13 October 2012 01:44, Chitra Creta wrote: > I currently have a table that is growing very quickly - i.e 7 million > records in 5 days. This table acts as a placeholder for statistics, and > hence the records are merely inserted and never updated or deleted. > > Many queries are run on thi

Re: [GENERAL] Postgres DB Migration from 8.3 to 9.1

2012-10-12 Thread Amitabh Kant
On Fri, Oct 12, 2012 at 7:45 AM, Vishalakshi Navaneethakrishnan < nvishalak...@sirahu.com> wrote: > Hi Friends, > > We have our production environment database server in Postgres 8.3 > version. we have planned to upgrade to lastest version 9.1. Dump from 8.3 > and restore in Postgres 9.1 takes mo

Re: [GENERAL] Strategies/Best Practises Handling Large Tables

2012-10-12 Thread Lonni J Friedman
On Fri, Oct 12, 2012 at 7:44 AM, Chitra Creta wrote: > Hi, > > I currently have a table that is growing very quickly - i.e 7 million > records in 5 days. This table acts as a placeholder for statistics, and > hence the records are merely inserted and never updated or deleted. > > Many queries are

[GENERAL] Strategies/Best Practises Handling Large Tables

2012-10-12 Thread Chitra Creta
Hi, I currently have a table that is growing very quickly - i.e 7 million records in 5 days. This table acts as a placeholder for statistics, and hence the records are merely inserted and never updated or deleted. Many queries are run on this table to obtain trend analysis. However, these queries

Re: [GENERAL] Limit+Offset query wrong result in Postgres 9.0.3 ?

2012-10-12 Thread Alban Hertroys
On 12 October 2012 04:55, urkpostenardr wrote: > Hi, > > Is this bug in Postgres ? > If yes, is it fixed in latest release ? > Second query should return 2 rows instead of 1 ? > > create table t(i int); > insert into t values(1); > insert into t values(2); > insert into t values(3); > pgdb=# selec

Re: [GENERAL] Limit+Offset query wrong result in Postgres 9.0.3 ?

2012-10-12 Thread Albe Laurenz
urkpostenardr wrote: > Is this bug in Postgres ? > If yes, is it fixed in latest release ? > Second query should return 2 rows instead of 1 ? > > create table t(i int); > insert into t values(1); > insert into t values(2); > insert into t values(3); > pgdb=# select i from t order by i limit 922337

Re: [GENERAL] How to raise index points when equal and like is used with gist ?

2012-10-12 Thread Sergey Konoplev
On Fri, Oct 12, 2012 at 1:20 AM, Condor wrote: > Even without tel filed result and type of scan is the same (Seq Scan). This is because your table has to few rows and it is easier to seq scan. Add more rows, eg. 100 000, then ANALYZE the table and run tests. Use random() and generate_series() to

Re: [GENERAL] How to raise index points when equal and like is used with gist ?

2012-10-12 Thread Condor
On 2012-10-12 03:27, Tom Lane wrote: Condor writes: explain analyze SELECT * FROM table WHERE phone LIKE '12%' AND firstname = 'OLEG' AND middlename || lastname LIKE '%KUZNICOV%IGORU%'; QUERY PLAN -

Re: [GENERAL] How to raise index points when equal and like is used with gist ?

2012-10-12 Thread Condor
On 2012-10-12 01:14, Sergey Konoplev wrote: On Thu, Oct 11, 2012 at 2:23 AM, Condor wrote: explain analyze SELECT * FROM table WHERE phone LIKE '12%' AND firstname = 'OLEG' AND middlename || lastname LIKE '%KUZNICOV%IGORU%';