Re: [GENERAL] VACUUM PANIC: corrupted item pointer

2008-10-17 Thread André Volpato
Tom Lane escreveu: =?ISO-8859-1?Q?Andr=E9_Volpato?= <[EMAIL PROTECTED]> writes: 8. Postgres is up, but... # psql matriz psql: FATAL: could not read block 0 of relation 1664/0/2676: read only 0 of 8192 bytes Looks like your raid array is dying under you :-( ... We hope it last more 3

Re: [GENERAL] VACUUM PANIC: corrupted item pointer

2008-10-17 Thread André Volpato
André Volpato escreveu: 10. Same error # psql matriz psql: FATAL: could not read block 0 of relation 1664/0/2676: read only 0 of 8192 bytes Right now this is the message I got every time I try to connect, even in single mode. We tried to fsck the raid partition, but with no luck. Hope

[GENERAL] VACUUM PANIC: corrupted item pointer

2008-10-17 Thread André Volpato
Hi, We got a corrupted database server, and I need some advice on what else can I do. Specs: - Postgres 8.3.3 @ Linux dbserver4 2.6.24-etchnhalf.1-686-bigmem - 4 GB RAM - PGDATA with 700GB (70GB used), software RAID-0 with 3 sata-2 (blame it on me, ugh...) So, the steps till now: 1 - Vacuum

Re: [GENERAL] Converting string to IN query

2008-09-12 Thread André Volpato
Andrus escreveu: SELECT * FROM invoices WHERE invoiceno IN ( '1,3,4' ); but this causes error. change it to ( '1','3','4' ) or ( 1,3,4 ) -- ACV -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/p

Re: [GENERAL] creating "a perfect sequence" column

2008-07-07 Thread André Volpato
ng SQL. Sure, there is a rownum() implementation from depesz [1] that works nice for reports. [1] http://www.depesz.com/index.php/2007/08/17/rownum-anyone-cumulative-sum-in-one-query/ -- André Volpato -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes t

Re: [GENERAL] PostgreSQL and MOLAP ?

2008-03-11 Thread André Volpato
fine. :) Try out JPivot too, Mondrian will give you MDX support, an JPivot is like a web frontend. Follow the instructions here [1] and good luck. [1] http://mondrian.pentaho.org/documentation/installation.php -- []´s, André Volpato Ecom Tecnologia LTDA - Análise e Desenvolvimento [EMAIL PROT

Re: [GENERAL] Hash join in 8.3

2007-12-14 Thread André Volpato
Gregory Stark escreveu: André Volpato <[EMAIL PROTECTED]> writes: I think I found the answer! 8.1: likes nested loop even after vacuumdb on the database. 8.3: likes hash at first time but: - after vacuumdb *on the database* (I was running on the tables.), it turns out to: Merg

Re: [GENERAL] Hash join in 8.3

2007-12-13 Thread André Volpato
er table before the bigger one. Tricky! I wont trust table vacuums anymore... -- []´s, André Volpato Ecom Tecnologia LTDA - Análise e Desenvolvimento [EMAIL PROTECTED]

Re: [GENERAL] Hash join in 8.3

2007-12-13 Thread André Volpato
u are talking about. To run this tests I disabled autovacuum, and run "vacuum analyze test / jtest" before. -- []´s, André Volpato Ecom Tecnologia LTDA - Análise e Desenvolvimento [EMAIL PROTECTED] ---(end of broadcast)--- TIP 1: if p

Re: [GENERAL] Hash join in 8.3

2007-12-13 Thread André Volpato
Gregory Stark escreveu: André Volpato <[EMAIL PROTECTED]> writes: And the query: # select j.i, t.t from jtest j inner join test t on t.i = j.i where (j.i*1.5) between 300 and 400; Planner for [1]: Nested Loop (cost=0.00..270192.02 rows=2 width=41) (actual Planner

[GENERAL] Hash join in 8.3

2007-12-13 Thread André Volpato
a compatibility test (I´m trying to figure out how many queries must be rewritten for 8.3) 2. Vacuum is up2date! 3. Is there any way to make [2] use the index ? -- []´s, André Volpato Ecom Tecnologia LTDA - Análise e Desenvolvimento [EMAIL PROTECTED] ---(end of broa

Re: [GENERAL] Creating indexes

2007-12-10 Thread André Volpato
, you show the desired html. -- []´s, André Volpato Ecom Tecnologia LTDA - Análise e Desenvolvimento [EMAIL PROTECTED] ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org/

Re: [GENERAL] Postgresql simple query performance question

2007-11-07 Thread André Volpato
Reid Thompson escreveu: On Tue, 2007-11-06 at 14:39 -0300, André Volpato wrote: Remember that you can always use serial fields to count a table, like: alter table foo add id serial; select id from foo order by id desc limit 1; This should return the same value than count(*), in

Re: [GENERAL] Postgresql simple query performance question

2007-11-06 Thread André Volpato
Richard Huxton escreveu: Reg Me Please wrote: While I would not spend resources in fine tuning the count(*), I would spend some to underastand why and how the other ones do it better. Just to be better. The problem is well understood, and there is extensive discussion in the mailing lists ar

[GENERAL] Filter sequence

2007-11-05 Thread André Volpato
Hi all, I´m experiencing an unexpected behaviour in the planner. I want the planner to apply a function in the results of a subquery, but its doing a filter in the hole table. The results between the mixed filters are the same in the end, but its taking ages. What I want is the planner to apll

Re: [GENERAL] Large Result and Memory Limit

2007-10-04 Thread André Volpato
Alvaro Herrera escreveu: Mike Ginsburg wrote: Hello, I am working on a personnel registry that has upwards of 50,000 registrants. Currently I am working on an export module that will create a CSV from multiple tables. I have managed to keep the script (PHP) under the memory l

Re: [GENERAL] Large Result and Memory Limit

2007-10-04 Thread André Volpato
Mike Ginsburg escreveu: André Volpato wrote: Mike Ginsburg escreveu: Hello, I am working on a personnel registry that has upwards of 50,000 registrants. Currently I am working on an export module that will create a CSV from multiple tables. I have managed to keep the script (PHP) under

Re: [GENERAL] Large Result and Memory Limit

2007-10-04 Thread André Volpato
Mike Ginsburg escreveu: Hello, I am working on a personnel registry that has upwards of 50,000 registrants. Currently I am working on an export module that will create a CSV from multiple tables. I have managed to keep the script (PHP) under the memory limit okay... some info needed here.

Re: [GENERAL] multiple row insertion

2007-10-04 Thread André Volpato
Alvaro Herrera escreveu: test tester escribió: On 10/4/07, test tester <[EMAIL PROTECTED]> wrote: i have version 8.1 and i want to know how to insert multiple rows in this version. Upgrade. Use COPY instead. Put you data into a var, and perf

[GENERAL] Metadata

2007-08-30 Thread André Volpato
Hello, I need constraint definitions like pg_indexes.indexdef , in order to drop / create them on the fly. BTW, where can I find a complete doc about Postgres Metadata ? - AV ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, pl

Re: [GENERAL] Data Mart with Postgres

2007-08-09 Thread André Volpato
int out another OLAP tool, that works with Postgres ? [1] http://mondrian.pentaho.org/ [2] http://jpivot.sourceforge.net -- []´s, André Volpato ECOM Tecnologia Ltda [EMAIL PROTECTED] (41) 3014 2322

[GENERAL] Data Mart with Postgres

2007-08-08 Thread André Volpato
is kind of application, wich demands materialyzed views, built-in bitmap index, and so on. In the open-source world, I find those missing features with Mondrian/JPivot. Does anyone has ever used this structure before ? At least Mondrian and JPivot ? --  []´s, André Volpato

Re: [GENERAL] PG for DataWarehouse type Queries

2007-08-03 Thread André Volpato
Postrgres? -- []´s, André Volpato ECOM Tecnologia Ltda [EMAIL PROTECTED] (41) 3014 2322 ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your

[GENERAL] Remove query results from cache

2007-05-23 Thread André Volpato
'forget' the results of any query until the cache reach 2 Gb (total box RAM) , or the server is rebooted. -- []´s, André Volpato ECOM Tecnologia Ltda [EMAIL PROTECTED] (41) 3014 2322 ---(end of broadcast)--- TIP 5: don't forget t

Re: [GENERAL] Faster data type for one-length values

2007-05-23 Thread André Volpato
André Volpato escreveu: Tom Lane escreveu: =?ISO-8859-1?Q?Andr=E9_Volpato?= <[EMAIL PROTECTED]> writes: I need to store one-length values like '1', '2', '3' or '4' . Today, this field is indexed with btree and is of type smallint (int2

Re: [GENERAL] Faster data type for one-length values

2007-05-23 Thread André Volpato
performance, in a search is based on that standalone indexed field, would be any difference using : a. char(1) ;  b. int2;  c. "char" Thanks again ! -- []´s, André Volpato ECOM Tecnologia Ltda [EMAIL PROTECTED] (41) 3014 2322

[GENERAL] Faster data type for one-length values

2007-05-23 Thread André Volpato
Hello, I need to store one-length values like '1', '2', '3' or '4' . Today, this field is indexed with btree and is of type smallint (int2). How much performance will be improved if I change it to "char" (1 byte length) ? Or int2 is the best s