Re: [GENERAL] fsync on ext4 does not work

2011-12-22 Thread Havasvölgyi Ottó
12/20 Greg Smith > On 12/19/2011 10:52 AM, Havasvölgyi Ottó wrote: > >> PgSql 9.1.2 >> Debian, 2.6.32 kernel >> WAL filesystem: ext4 with defaults >> > > There's a pg_test_fsync program included with the postgresql-contrib > package that might help you sort

Re: [GENERAL] fsync on ext4 does not work

2011-12-21 Thread Havasvölgyi Ottó
Thank you guys for the ideas and suggestions, I will check them. Best regards, Otto

Re: [GENERAL] fsync on ext4 does not work

2011-12-19 Thread Havasvölgyi Ottó
2011/12/19 Florian Weimer > * Havasvölgyi Ottó: > > > Even though the TPS in pgbench about 700 with 1 client. > > I have tried other sync methods (fdatasync, open_sync), but all are > similar. > > Should I disable write cache on HDD to make it work? > > Did you

Re: [GENERAL] fsync on ext4 does not work

2011-12-19 Thread Havasvölgyi Ottó
2011/12/19 Tomas Vondra > On 19 Prosinec 2011, 16:52, Havasvölgyi Ottó wrote: > > config: > > fsync=on > > sync_commit=on > > wal_sync_method=fsync > > I don't think you need to set wal_sync_method, comment it out. > > > Even though the TPS in pg

[GENERAL] fsync on ext4 does not work

2011-12-19 Thread Havasvölgyi Ottó
Hi all, Somewhy fsync does not work for me. PgSql 9.1.2 Debian, 2.6.32 kernel WAL filesystem: ext4 with defaults config: fsync=on sync_commit=on wal_sync_method=fsync Even though the TPS in pgbench about 700 with 1 client. I have tried other sync methods (fdatasync, open_sync), but all are s

Re: [GENERAL] Rounding incompatibility

2009-06-16 Thread Havasvölgyi Ottó
Yes, they are both your packages from your official site. So this means that in 8.2 and in earlier versions the rounding is not the regular one. Best regards, Otto 2009/6/15 Dave Page > On Mon, Jun 15, 2009 at 3:33 PM, Tom Lane wrote: > > =?ISO-8859-1?Q?Havasv=F6lgyi_Ott=F3?= > writes: > >> I

[GENERAL] Rounding incompatibility

2009-06-15 Thread Havasvölgyi Ottó
Hi, I have found the following strangeness on Windows versions: create table round_test (id int primary key, value double precision); insert into round_test(id, value) values(1, 1.5); insert into round_test(id, value) values(2, -1.5); insert into round_test(id, value) values(3, 3.5); select round

Re: [GENERAL] Trigger Function and backup

2009-06-15 Thread Havasvölgyi Ottó
Hi, I have found the following strangeness on Windows: create table round_test (id int primary key, value double precision); insert into round_test(id, value) values(1, 1.5); insert into round_test(id, value) values(2, -1.5); insert into round_test(id, value) values(3, 3.5); select round(value) f

Re: [GENERAL] 8.3: timestamp subtraction

2009-05-24 Thread Havasvölgyi Ottó
Thanks Tom for your comments. I meant the build in this directory: http://www.postgresql.org/ftp/binary/v8.3.6/win32/, and the builds for win32 of other versions in the binary directory. What is the trend of these builds regarding floating point timestamps? For example what about 8.4? Thanks, Ott

Re: [GENERAL] 8.3: timestamp subtraction

2009-05-23 Thread Havasvölgyi Ottó
Thanks, It's off in both 8.2 and 8.3. What will be the default in 8.4? Best regards, Otto 2009/5/23 Alvaro Herrera > Havasvölgyi Ottó escribió: > > I mean the Win32 distribution on the PgSql site. I always used that. > > If you want to find out whether a particular build us

Re: [GENERAL] 8.3: timestamp subtraction

2009-05-23 Thread Havasvölgyi Ottó
I mean the Win32 distribution on the PgSql site. I always used that. It would be very good if these data types were exact by default, even if that's a bit slower. Otto 2009/5/23 Christophe > > On May 23, 2009, at 10:44 AM, Havasvölgyi Ottó wrote: > > Thanks. >> I te

Re: [GENERAL] 8.3: timestamp subtraction

2009-05-23 Thread Havasvölgyi Ottó
regards, Otto 2009/5/23 Havasvölgyi Ottó > Thanks. > I tested the standard Win32 distribution of 8.3.6. > The same happens on 8.2. But on 8.0 it works. > > When I don't use milliseconds, then it works. > > Will 8.4 work fine on Win32 again? > > Thanks, > Otto > > &

Re: [GENERAL] 8.3: timestamp subtraction

2009-05-23 Thread Havasvölgyi Ottó
Thanks. I tested the standard Win32 distribution of 8.3.6. The same happens on 8.2. But on 8.0 it works. When I don't use milliseconds, then it works. Will 8.4 work fine on Win32 again? Thanks, Otto 2009/5/23 Ludwig Kniprath > Scott Marlowe schrieb: > >> On Sat, May 23, 2009 at 7:18 AM, Chr

[GENERAL] 8.3: timestamp subtraction

2009-05-23 Thread Havasvölgyi Ottó
Hi, I don't know why this query returns false: SELECT '20040506 070809.01'::timestamp(6) - '20010203 040506.007000'::timestamp(6) = '1188 day 3 hour 3 minute 3 second 3 millisecond'::interval; If I just subtract the two timestamps, its result is the interval I specified. What may cause this?

[GENERAL] Some rare questions

2005-12-04 Thread Havasvölgyi Ottó
Hi, I am writing a driver for PostgreSQL, and I need some rare info: How can I query the collation/locale of the database cluster? What can be the maximal length of the indexed part of the string. So I have a text field, and I create an index on it. How long can be one index key max in this

[GENERAL] Creating then dropping primary key constraint

2005-12-04 Thread Havasvölgyi Ottó
Hi, I noticed that when I create a primary key with ALTER TABLE ... ADD CONSTRAINT ... PRIMARY KEY (...), and then drop this constraint, then the "not null" modifier stays on the column on which the primary key was defined although there were no constraint on that column before. Is this norma

[GENERAL] PL/PGSQL parameter count vs perfomace

2005-08-10 Thread Havasvölgyi Ottó
Hi, I would sometimes need a lot of parameters, even 100 or so. These would be the data access functions for tables. I know the default count limit is 32, and FUNC_MAX_ARGS compile option should be set to, say, 256. But I have another option, a bit harder, I could pass the parameters in a reco

[GENERAL] explain analyzing a query inside an sql stored procedure

2005-08-04 Thread Havasvölgyi Ottó
Hi, Is there any easy way to explain analyze a query, which is inside an sql stored procedure? I could of course copy the query out of the procedure, and explain analyze it but this is a slower process. I would do this with a lot of procedures, that's why it should be fast. create function m

Re: [GENERAL] dbf to pgsql

2005-08-04 Thread Havasvölgyi Ottó
Peter, There is a dbf2pg in the contrib library, I have tried to use it, but I had some probems with it: I had a numeric field whose decimal length was 0. Dbf2pg couldn't handle this situation, it said that it has an illegel number format. So I had to generate manually a big convertion script,

Re: [GENERAL] feeding big script to psql

2005-08-03 Thread Havasvölgyi Ottó
Tom, My queries were written in multi-line mode like this: insert into t1 values(1, 2, 3); I don't know, what effect this has to performace.. Regards, Otto - Original Message - From: "Tom Lane" <[EMAIL PROTECTED]> To: "Havasvölgyi Ottó" <[EMAI

Re: [GENERAL] feeding big script to psql

2005-08-02 Thread Havasvölgyi Ottó
application did anything. No other HDD activity either. Best Regadrs, Otto - Original Message - From: "Scott Marlowe" <[EMAIL PROTECTED]> To: "Havasvölgyi Ottó" <[EMAIL PROTECTED]> Cc: "Tom Lane" <[EMAIL PROTECTED]>; Sent: Tuesday, August 02,

Re: [GENERAL] feeding big script to psql

2005-08-02 Thread Havasvölgyi Ottó
Hi, Now I am at 7 MB, and the reading speed is 3-4KB/sec. Best Regards, Otto - Original Message - From: "Havasvölgyi Ottó" <[EMAIL PROTECTED]> To: Sent: Tuesday, August 02, 2005 1:31 PM Subject: Re: [GENERAL] feeding big script to psql Hi, The effect is th

Re: [GENERAL] feeding big script to psql

2005-08-02 Thread Havasvölgyi Ottó
Hi, The effect is the same even if I redirect the output to file with the -o switch. At the beginning 200 KB/sec, at 1.5 MB the speed is less than 20 KB/sec. Best Regards, Otto - Original Message - From: "Havasvölgyi Ottó" <[EMAIL PROTECTED]> To: "Tom Lane&qu

Re: [GENERAL] feeding big script to psql

2005-08-02 Thread Havasvölgyi Ottó
. Maybe others should also try this scenario. Can I help anything? Best Regards, Otto - Original Message - From: "Tom Lane" <[EMAIL PROTECTED]> To: "Havasvölgyi Ottó" <[EMAIL PROTECTED]> Cc: Sent: Tuesday, August 02, 2005 3:54 AM Subject: Re: [GENERAL] fee

[GENERAL] feeding big script to psql

2005-08-01 Thread Havasvölgyi Ottó
Hi, A generated a big SQL script (about 20 Mb), and fed it to psql. I was very surprised that within a minute psql became quite slow. There were areas, where less than 10 row were inserted in a second. This is on a WinXP machine with local server 8.0.3, and only I use it. Looking at the log fi

Re: [GENERAL] Select for update

2005-07-29 Thread Havasvölgyi Ottó
gt; To: "Havasvölgyi Ottó" <[EMAIL PROTECTED]> Cc: Sent: Friday, July 29, 2005 3:12 AM Subject: Re: [GENERAL] Select for update On Fri, Jul 29, 2005 at 12:05:46AM +0200, Havasvölgyi Ottó wrote: create function pidtest_del(_pid integer) returns void as $$ declare row pidtest; beg

Re: [GENERAL] Select for update

2005-07-29 Thread Havasvölgyi Ottó
Bruno, I know this is inefficient. In fact it was someone other's problem to eliminate gaps and I solved it this way. I don't do such things for myself. Best Regards, Otto - Original Message - From: "Bruno Wolff III" <[EMAIL PROTECTED]> To: "Hava

Re: [GENERAL] Select for update

2005-07-28 Thread Havasvölgyi Ottó
present any more. Sorry, now I cannot reproduce it, but yesterday I was suprised that the szoveg field's contents in the locked records went away. Best Regards, Otto - Original Message - From: "Michael Fuhr" <[EMAIL PROTECTED]> To: "Havasvölgyi Ottó&quo

[GENERAL] Select for update

2005-07-28 Thread Havasvölgyi Ottó
Hi, Is it normal that when I select for update a record, but I don't select all the fields, that the contents of fields not selected will be deleted: create table pidtest(pid integer, szoveg text) without oids; select pid from pistest where pid>5 for update; After committing (autocommit), th

Re: [GENERAL] checkpoint segments

2005-07-09 Thread Havasvölgyi Ottó
Hi, Sorry, this is Pg 8.0.3 Regards, Otto ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match

[GENERAL] checkpoint segments

2005-07-09 Thread Havasvölgyi Ottó
Hi, I have a small database on my Windows XP, I rarely use it. Even so, the log file show says this: [2005-07-02 02:02:09] LOG: received fast shutdown request [2005-07-02 02:02:09] LOG: checkpoints are occurring too frequently (0 seconds apart) [2005-07-02 02:02:09] HINT: Consider increasi

[GENERAL] field alias in where condition

2005-06-03 Thread Havasvölgyi Ottó
Hi all, I issued the following queries: select substring(proname from 1 to 1) as nevresz, count(*) from pg_proc where nevresz = 'a' order by nevresz group by nevresz; select substring(proname from 1 to 1) as nevresz, count(*) from pg_proc order by nevresz group by nevresz; The first que

Re: [GENERAL] interval integer comparison

2005-06-01 Thread Havasvölgyi Ottó
rrent_date + '21 days'::interval; Best Regards, Otto - Original Message - From: "Tom Lane" <[EMAIL PROTECTED]> To: "Havasvölgyi Ottó" <[EMAIL PROTECTED]> Cc: Sent: Tuesday, May 31, 2005 5:46 PM Subject: Re: [GENERAL] interval integer compari

Re: [GENERAL] Accessing PostgreSQL from C++

2005-05-31 Thread Havasvölgyi Ottó
Jeff, Yes, libpq. Look at the 27th chapter in the manual. Otto - Original Message - From: "Jeff Brown" <[EMAIL PROTECTED]> To: Sent: Tuesday, May 31, 2005 8:31 AM Subject: [GENERAL] Accessing PostgreSQL from C++ > Hi guys > > Is there some sort of C API available for PostgreSQL? >

[GENERAL] interval integer comparison

2005-05-31 Thread Havasvölgyi Ottó
Hi all, Pg 8.0.3 allows me to compare interval with integer, but I cannot see any reasonable rule: These are true: 1 < '1 days'::interval 2 > '1 days'::interval 999 > '1 days'::interval 1999 < '2 days'::interval 2000 != '2 days'::interval 2001 > '2 days'::interval ... 20999 < '21 days'::i

[GENERAL] Manipulating a dataset on the client side

2005-02-25 Thread Havasvölgyi Ottó
Hi,   Situation: The client program queries a dataset from the PG server, and it displays it, say, in a table. The user can navigate and update fields, insert new records, delete records. And any change should be visible on all clients. I think I have basically 2 choices:  1 : using SELECT and