Re: [HACKERS] Build farm

2003-11-24 Thread Jean-Michel POURE
Le Vendredi 21 Novembre 2003 19:47, Tom Lane a Ãcrit :
> I think the main value of a build farm is that we'd get nearly immediate
> feedback about the majority of simple porting problems. ÂYour previous
> arguments that it wouldn't smoke everything out are certainly valid ---
> but we wouldn't abandon the regression tests just because they don't
> find everything. ÂImmediate feedback is good because a patch can be
> fixed while it's still fresh in the author's mind.

Dear friends,

We have a small build farm for pgAdmin covering Win32, FreeBSD and most GNU/
Linux systems. See http://www.pgadmin.org/pgadmin3/download.php#snapshots

The advantage are immediate feedback and correction of problems. Also, in a 
release cycle, developers and translators are quite motivated to see their 
work published fast. 

Of course, it is always hard to "mesure" the real impact of a build farm. My 
opinion it that it is quite positive, as it helps tighten the links between 
people, which is free software is mostly about.

Cheers,
Jean-Michel PourÃ



---(end of broadcast)---
TIP 7: don't forget to increase your free space map settings


Re: [HACKERS] Sponsoring enterprise features

2003-11-24 Thread Zeugswetter Andreas SB SD

Main needs partitioning is useful for:
- partition elimination for queries (e.g. seq scans only scan relevant partitions)
- deleting/detaching huge parts of a table in seconds
- attaching huge parts to a table in seconds (that may have been loaded with
a fast loading utility (e.g. loading without index, prebuilding indexes,
attaching table + prebuilt partitioned indexes)) 
- achieving [heap and index] per page data locality (for better cache rates)
- allowing partial restores (for defect disks) while the rest of the db is still online
- in pg, allowing partial vacuums (only partitions that see changes)

People needing those features usually have data with more than 10-50 Gb per 
partition. 

> I'm a little unclear, personally, about what can be accomplished through table 
> partitioning that we can't currently do through partial indexes and inherited 
> tables, especially after Gavin finishes his tablespaces patch

Well, sure the goal needs to be to make use of what already exists,
but a few things are still missing, e.g.:
 - unique indexes, that span the hierarchy (and do not contain the partitioning 
column[s])
 - partition elimination (imho we should use check constraints for that)
 - physical backups :-)
 - tablespaces ?

Note, that these would all be useful for non partitioning 
use cases also.

Andreas

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])


Re: [HACKERS] Build farm

2003-11-24 Thread Andrew Dunstan


Jean-Michel POURE wrote:

Le Vendredi 21 Novembre 2003 19:47, Tom Lane a Ãcrit :
 

I think the main value of a build farm is that we'd get nearly immediate
feedback about the majority of simple porting problems.  Your previous
arguments that it wouldn't smoke everything out are certainly valid ---
but we wouldn't abandon the regression tests just because they don't
find everything.  Immediate feedback is good because a patch can be
fixed while it's still fresh in the author's mind.
   

Dear friends,

We have a small build farm for pgAdmin covering Win32, FreeBSD and most GNU/
Linux systems. See http://www.pgadmin.org/pgadmin3/download.php#snapshots
The advantage are immediate feedback and correction of problems. Also, in a 
release cycle, developers and translators are quite motivated to see their 
work published fast. 

Of course, it is always hard to "mesure" the real impact of a build farm. My 
opinion it that it is quite positive, as it helps tighten the links between 
people, which is free software is mostly about.

 

Right. But I think we have been talking about using the build farm to do 
test builds rather than to provide snapshots. I'd be very wary of 
providing arbitrary snapshots of postgres, whereas I'd be prepared to 
try a snapshot of pgadmin3 under certain circumstances. (Also, building 
your own snapshot of postgres is somewhat easier than building your own 
snapshot of pgadmin3).

cheers

andrew

---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
 subscribe-nomail command to [EMAIL PROTECTED] so that your
 message can get through to the mailing list cleanly


Re: [HACKERS] Executable files in CVS

2003-11-24 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes:
> Tom Lane writes:
>> Besides, it's a tad odd to see files that are marked group writable but
>> not owner writable.  You've got to agree there's not much sense in that.

> How else are you going to commit files?  /usr/bin/cvs is not setuid,

Sure, but as long as the directories are group-writable it can rename
the old version out of the way.  Which is what I think it's actually
doing, because there are some files in the tree that are not group
writable --- src/backend/commands/alter.c,v is an example.

regards, tom lane

---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster


Re: [HACKERS] Build farm

2003-11-24 Thread Andreas Pflug
Andrew Dunstan wrote:



Jean-Michel POURE wrote:

Le Vendredi 21 Novembre 2003 19:47, Tom Lane a Ãcrit :
 

I think the main value of a build farm is that we'd get nearly 
immediate
feedback about the majority of simple porting problems.  Your previous
arguments that it wouldn't smoke everything out are certainly valid ---
but we wouldn't abandon the regression tests just because they don't
find everything.  Immediate feedback is good because a patch can be
fixed while it's still fresh in the author's mind.
  


Dear friends,

We have a small build farm for pgAdmin covering Win32, FreeBSD and 
most GNU/
Linux systems. See 
http://www.pgadmin.org/pgadmin3/download.php#snapshots

The advantage are immediate feedback and correction of problems. 
Also, in a release cycle, developers and translators are quite 
motivated to see their work published fast.
Of course, it is always hard to "mesure" the real impact of a build 
farm. My opinion it that it is quite positive, as it helps tighten 
the links between people, which is free software is mostly about.

 

Right. But I think we have been talking about using the build farm to 
do test builds rather than to provide snapshots. I'd be very wary of 
providing arbitrary snapshots of postgres, whereas I'd be prepared to 
try a snapshot of pgadmin3 under certain circumstances. (Also, 
building your own snapshot of postgres is somewhat easier than 
building your own snapshot of pgadmin3).
Testing a build and creating a snapshot compilation is quite the same, 
just a different name and announcement. I agree that using a pgadmin 
snapshot is different from pgsql, somebody using a bleeding edge pgsql 
version should be prepared to compile it on his own machine.

And a tiny correction: The farm member for win32 is my machine, and it's 
operated manually :-)

Regards,
Andreas


---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
 subscribe-nomail command to [EMAIL PROTECTED] so that your
 message can get through to the mailing list cleanly


Re: [HACKERS] ALTER SEQUENCE enchancement

2003-11-24 Thread Rod Taylor
On Mon, 2003-11-24 at 01:07, Christopher Kings-Lynne wrote:
> Hi,
> 
> Is there demand for this syntax:
> 
> ALTER SEQUENCE ON table(col) CYCLE 100;
> 
> It would allow us to become sequence-name independent...

I think the right approach to this problem would be to implement
IDENTITIES and GENERATORS per 2k3 spec -- almost what you show here.

Check DB2 docs for examples.


---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]


Re: [HACKERS] Build farm

2003-11-24 Thread Jean-Michel POURE
Le Lundi 24 Novembre 2003 16:38, Andreas Pflug a Ãcrit :
> And a tiny correction: The farm member for win32 is my machine, and it's
> operated manually :-)

Some GNU/Linux farm animals are living in my garage running on very old 50 
euros machines ... Ancient farming :-)

By the way, we would love if someone could provide pgAdmin3 daily snapshots 
under other systems. The list of platforms can be viewed here, anyone is 
welcome to provide additional ones:

http://www.pgadmin.org/pgadmin3/download.php#snapshots

Cheers, Jean-Michel


---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]


Re: [HACKERS] ALTER SEQUENCE enchancement

2003-11-24 Thread Neil Conway
Christopher Kings-Lynne <[EMAIL PROTECTED]> writes:
> Is there demand for this syntax:
>
> ALTER SEQUENCE ON table(col) CYCLE 100;

What if the values in a column are generated via a sequence that was
created independently -- i.e. it's not a SERIAL column?

I'm not very enthusiastic about features that assume a one-to-one
mapping between sequences and columns; in general, the mapping is
many-to-many.

-Neil


---(end of broadcast)---
TIP 6: Have you searched our list archives?

   http://archives.postgresql.org


[HACKERS] CVS HEAD is broken

2003-11-24 Thread Neil Conway
With a recent snapshot of CVS HEAD:

make[1]: Leaving directory `/home/nconway/build-pgsql-cvs/src/backend/parser'
gcc -O0 -g -Wall -Wmissing-prototypes -Wmissing-declarations 
-I/home/nconway/pgsql/src/interfaces/libpq -I../../../src/include 
-I/home/nconway/pgsql/src/include -D_GNU_SOURCE  -DBINDIR=\"/pgsql/bin\"  -c -o 
pg_dump.o /home/nconway/pgsql/src/bin/pg_dump/pg_dump.c -MMD
/home/nconway/pgsql/src/bin/pg_dump/pg_dump.c:4777:34: missing terminating " character
/home/nconway/pgsql/src/bin/pg_dump/pg_dump.c: In function `dumpOneConversion':
/home/nconway/pgsql/src/bin/pg_dump/pg_dump.c:4778: error: parse error before 
"pg_catalog"
/home/nconway/pgsql/src/bin/pg_dump/pg_dump.c:4782:47: warning: multi-character 
character constant
/home/nconway/pgsql/src/bin/pg_dump/pg_dump.c:4782:67: missing terminating " character
make: *** [pg_dump.o] Error 1

String literals with embedded newline have been deprecated for a
couple GCC releases, and are no longer supported.

$ cc --version
cc (GCC) 3.3.2 (Debian)
$ uname -a
Linux tokyo 2.6.0-test9 #2 Fri Oct 31 19:32:35 EST 2003 i686 GNU/Linux

-Neil


---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster


[HACKERS] How can I avoid that

2003-11-24 Thread ohp
Hi all,

I know you're all busy with 7.4 comming out and I was wondering if some
one could have an idea about the following:

I host a game that does a HEAVY use of postgresql working like a charm.
But when the server is a little busy (like when Marc approves a WAG of
mail), postgresql dosn't respond so fast and users start clicking on the
reload button, making a new connection, re-issuing the query and so forth.

Now those "slow" query seem to last forever (several minutes CPU). My guts
feel thatpostgresql doesn't have a clue that the connection with web
server is broken and just continue to run.

Can I avoid that?

Regards

-- 
Olivier PRENANT Tel: +33-5-61-50-97-00 (Work)
6, Chemin d'Harraud Turrou   +33-5-61-50-97-01 (Fax)
31190 AUTERIVE   +33-6-07-63-80-64 (GSM)
FRANCE  Email: [EMAIL PROTECTED]
--
Make your life a dream, make your dream a reality. (St Exupery)

---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
  joining column's datatypes do not match


[HACKERS] Using -Wshadow

2003-11-24 Thread Neil Conway
GCC supports the -Wshadow command-line option:

   -Wshadow
   Warn whenever a local variable shadows another local
   variable, parameter or global variable or whenever a
   built-in function is shadowed.

Currently, enabling this for the PostgreSQL tree produces a lot of
warnings. Would anyone object if I corrected these usages of a
shadowed local variable, and then enabled this warning flag for
standard GCC builds? (as is currently done for -Wmissing-prototypes,
-Wmissing-declarations, and -Wall).

If there are any other GCC warning flags anyone else feels would be
useful, let me know.

-Neil


---(end of broadcast)---
TIP 6: Have you searched our list archives?

   http://archives.postgresql.org


Re: [HACKERS] CVS HEAD is broken

2003-11-24 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes:
> String literals with embedded newline have been deprecated for a
> couple GCC releases, and are no longer supported.

[grumble] ... the great thing about gcc is there are so many
incompatible versions to choose from.

I fixed the occurrence at pg_dump.c line 4777, do you see any others?

regards, tom lane

---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?

   http://www.postgresql.org/docs/faqs/FAQ.html


[HACKERS] regexp incompatibilites 7.3 and 7.4

2003-11-24 Thread Oleg Bartunov
Hi,

seems for regexp which works in 7.3 is failing in 7.4.
Is't possible to configure pgsql to be compatible with 7.3 regexp ?

Welcome to psql 7.3.4, the PostgreSQL interactive terminal.

Type:  \copyright for distribution terms
   \h for help with SQL commands
   \? for help on internal slash commands
   \g or terminate with semicolon to execute query
   \q to quit

discovery=#  select 'problem' ~ '^\\p';
 ?column?
--
 t
(1 row)


Welcome to psql 7.4, the PostgreSQL interactive terminal.

Type:  \copyright for distribution terms
   \h for help with SQL commands
   \? for help on internal slash commands
   \g or terminate with semicolon to execute query
   \q to quit

www=# select 'problem' ~ '^\\p';
ERROR:  invalid regular expression: invalid escape \ sequence


Regards,
Oleg
_
Oleg Bartunov, sci.researcher, hostmaster of AstroNet,
Sternberg Astronomical Institute, Moscow University (Russia)
Internet: [EMAIL PROTECTED], http://www.sai.msu.su/~megera/
phone: +007(095)939-16-83, +007(095)939-23-83

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])


Re: [HACKERS] Using -Wshadow

2003-11-24 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes:
> GCC supports the -Wshadow command-line option:
>-Wshadow
>Warn whenever a local variable shadows another local
>variable, parameter or global variable or whenever a
>built-in function is shadowed.

> Currently, enabling this for the PostgreSQL tree produces a lot of
> warnings. Would anyone object if I corrected these usages of a
> shadowed local variable, and then enabled this warning flag for
> standard GCC builds?

How many is "a lot"?  What are the odds that this would produce spurious
warnings on some platforms due to shadowing of platform-specific
functions or globals?

I wouldn't object to something that catches shadowings of parameters or
local variables, but I think the flag as defined is not very useful.


> If there are any other GCC warning flags anyone else feels would be
> useful, let me know.

I have for a long time wanted to enable -Wcast-align and -Wpointer-arith,
but so far the tedium of getting rid of the warnings exceeds my
enthusiasm for it.

Another nice thing would be to get rid of the warnings about casting
between "char" and "unsigned char" that pop up on many (most?) non-gcc
compilers.  Most of the occurrences are in or near the multibyte stuff,
so maybe this could be coordinated somehow with Peter's plans for
upgrading locale support.

regards, tom lane

---(end of broadcast)---
TIP 7: don't forget to increase your free space map settings


Re: [HACKERS] Using -Wshadow

2003-11-24 Thread Kurt Roeckx
On Mon, Nov 24, 2003 at 12:25:32PM -0500, Neil Conway wrote:
> If there are any other GCC warning flags anyone else feels would be
> useful, let me know.

I find the following also useful:
-Wcast-align
-Wcast-qual
-Wpointer-arith
-Wstrict-prototypes

And maybe:
-Waggregate-return


Kurt


---(end of broadcast)---
TIP 8: explain analyze is your friend


Re: [HACKERS] regexp incompatibilites 7.3 and 7.4

2003-11-24 Thread Tom Lane
Oleg Bartunov <[EMAIL PROTECTED]> writes:
> seems for regexp which works in 7.3 is failing in 7.4.
> Is't possible to configure pgsql to be compatible with 7.3 regexp ?

SET regex_flavor TO extended;

> www=# select 'problem' ~ '^\\p';
> ERROR:  invalid regular expression: invalid escape \ sequence

I think, though, that this is telling you about a bug in your
application.  You do realize that under extended regex rules there's
no difference between that pattern and '^p' ?  Is that *really* what
you want?

regards, tom lane

---(end of broadcast)---
TIP 6: Have you searched our list archives?

   http://archives.postgresql.org


Re: [HACKERS] Sponsoring enterprise features

2003-11-24 Thread Hannu Krosing
Zeugswetter Andreas SB SD kirjutas E, 24.11.2003 kell 13:16:
> Main needs partitioning is useful for:
> - partition elimination for queries (e.g. seq scans only scan relevant partitions)
> - deleting/detaching huge parts of a table in seconds
> - attaching huge parts to a table in seconds (that may have been loaded with
>   a fast loading utility (e.g. loading without index, prebuilding indexes,
>   attaching table + prebuilt partitioned indexes)) 
> - achieving [heap and index] per page data locality (for better cache rates)
> - allowing partial restores (for defect disks) while the rest of the db is still 
> online
> - in pg, allowing partial vacuums (only partitions that see changes)
> 
> People needing those features usually have data with more than 10-50 Gb per 
> partition. 
> 
> > I'm a little unclear, personally, about what can be accomplished through table 
> > partitioning that we can't currently do through partial indexes and inherited 
> > tables, especially after Gavin finishes his tablespaces patch

Partial indexes don't solve the basic clustering problem (need for
reading too many pages).

Using inherited tables for this somehow seems conceptually wrong, though
this may solve the clustering problem. Also, indexes don't currently
cover child tables, but this may be thought of as an implementation
deficiency.

But some mechanisms used for inheritance could likely be used as basis
for partitioning.

> Well, sure the goal needs to be to make use of what already exists,
> but a few things are still missing, e.g.:
>  - unique indexes, that span the hierarchy (and do not contain the partitioning 
> column[s])

We kind of have these - a unique index can nicely be built over table
stored in several 1GB files. Now we must just make sure that seqscans
know about the gaps if files are not full 1GB in size.

BTW, does VACUUM FULL shrink individual files or will it move tuples
between files when shrinking the storage ?

Are interfaces to sparse files portable enough that we could use these ?

>  - partition elimination (imho we should use check constraints for that)

or partial indexes

or smart clustering which can make use of several partitions depending
on the possition of the tuple in the index(es) used for clustering.

>  - physical backups :-)

Do you mean read-only partitions which can come and go?

>  - tablespaces ?

Tablespaces should be an orthogonal feature, mainly about efficient
storage. We could like to spread partitions of the same table over
several tablespaces.

> Note, that these would all be useful for non partitioning 
> use cases also.

True.

---
Hannu



---(end of broadcast)---
TIP 8: explain analyze is your friend


[HACKERS] Considerations for lib64

2003-11-24 Thread Peter Eisentraut
Some systems that can run 32-bit and 64-bit executables have lib64
directories alongside lib directories.  (You could also imagine any other
alternative compilation mode in place of "64".)  This requires some
adjustments in the PostgreSQL build system.

Currently, when you specify --with-openssl, then configure automatically
adds -L/usr/local/ssl/lib to LDFLAGS if that directory exists.  This would
pick up the wrong directory if you are in 64-bit mode.  Analogous behavior
exists for --with-krb5 with /usr/athena.

I think these default installation directories of OpenSSL and Kerberos are
mostly obsolete these days, so I'd rather get rid of that behavior
altogether and let people specify the necessary directories with
--with-libraries and --with-includes like for any of the other optional
packages that PostgreSQL supports.

Comments?

(Additional lib64 issues exist with Python; I will post about these
later.)

-- 
Peter Eisentraut   [EMAIL PROTECTED]


---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
  subscribe-nomail command to [EMAIL PROTECTED] so that your
  message can get through to the mailing list cleanly


Re: [HACKERS] Using -Wshadow

2003-11-24 Thread Neil Conway
Tom Lane <[EMAIL PROTECTED]> writes:
> Neil Conway <[EMAIL PROTECTED]> writes:
>> Currently, enabling this for the PostgreSQL tree produces a lot of
>> warnings.
>
> How many is "a lot"?

Maybe a couple hundred or so, but most of the warnings are derived
from a few globals with common names -- I would guess it won't be too
much trouble to fix...

> What are the odds that this would produce spurious warnings on some
> platforms due to shadowing of platform-specific functions or
> globals?

No idea -- I'm content to jump that bridge (e.g. by removing -Wshadow
if necessary) when we come to it.

Ok, I'll work on this and submit a patch to -patches when I'm
done. I'll leave the work on the other warning flags you mentioned for
someone else.

-Neil


---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])


[HACKERS] A rough roadmap for internationalization fixes

2003-11-24 Thread Peter Eisentraut
OK, I've been spreading rumours about fixing the internationalization
problems, so let me make it a bit more clear.  Here are the problems that
need to be fixed:

- Only one locale per process possible.

- Only one gettext-language per process possible.

- lc_collate and lc_ctype need to be held fixed in the entire cluster.

- Gettext relies on iconv character set conversion, which relies on
  lc_ctype, which leads to a complete screw-up in the server because of
  the previous item.

- Locale fixed per cluster, but encoding fixed per database, unware
  of each other, don't get along.

- No support for upper/lower with multibyte encoding.

- Implementation of Unicode horribly incomplete.

These are all dependent on each other and sort of flow into each other.

Here is a proposed ordering of steps toward improving the situation:

1. Take out the character set conversion routines from the backend and
make them a library of their own.  This could possibly be modelled after
iconv, but not necessarily.  Or we might conclude that we can just use
iconv in the first place.

2. Reimplement gettext to use 1. and allow switching of language and
encoding at run-time.

3. Implement Unicode collation algorithm and character classification
routines that are aware of 1.  Use that in place of system locale
routines.

4. Allow choice of locale per database.  (This should be fairly easy after
3.)

5. Allow choice of locale per column and implement collation coercion
according to SQL standard.

This could easily take a long time, but I feel that even if we have to
stop after 2., 3., or 4. at feature freeze, we'd be a lot farther.

Comments?  Anything else that needs fixing?

-- 
Peter Eisentraut   [EMAIL PROTECTED]


---(end of broadcast)---
TIP 6: Have you searched our list archives?

   http://archives.postgresql.org


Re: [HACKERS] Commercial binary support?

2003-11-24 Thread Austin Gonyou
On Sat, 2003-11-22 at 11:43, Nigel J. Andrews wrote:
> On Wed, 19 Nov 2003, Joshua D. Drake wrote:
> 
> > Hello,
> > 
> >   I think what the person is looking for is:
> > 
> >   COMPANY PostgreSQL for Red Hat Enterprise 3.0.
> > 
> >   They probably have some commercial mandate that says that they have
> > to have a commercial company backing the product itself. This doesn't
> > work for most PostgreSQL companies because they back the "Open Source"
> > version of PostgreSQL.
> > 
> >   Where someone like Command Prompt, although we happily support the
> > Open Source version, we also sell Command Prompt PostgreSQL.
> 
> That was sort of my point. I currently have a 7.3 installation for which I have
> my own patches applied, for tsearch2, and for which I run my own CVS of the
> cpntrob module. It seems this module isn't maintained in the community, what
> with it being a 7.4 thing really. My company is the sys. admin., DBA and DB
> developer for the project, except for the production server sys. admin.. These
> mods weren't applied because the client was asking for them but because I knew
> the faults existed, even though the project wasn't kicking them.

If the patches you wrote are your own, to fix a problem, and not
reviewed by the OSS community and incorporated into an OSS project/code
base, then it would be your own proprietary modification to an OSS
codebase, and thus, if not commonly accepted, becomes yours to "own" and
sell to clients, etc Then, it's not default Postgresql from the OSS
stream. 

> Does that mean I have supplied Logictree Systems PostgreSQL? PostgreSQL with
> Logictree Systems TSearch2? And if I'd made no modifications to the code? I
> suppose I could have insisted that a separate contract be taken for the supply
> and support on top of the app. development contract. In fact, having written
> that I'm starting to think that should be the case.
> 

The thing to remember about the above, is that if your solution
eventually gets that OSS community "approval" or review, and accepted
into an open codebase and thus incorporated into a project, with
everyone's agreement, and thus becomes standard for distribution, your
code is no longer proprietary as it was accepted as the open default
solution to a problem or whatever in an open code base. 

If the latter never occurs, then I'd say, yes, you *could[read:
should?]* sell support for your modifications and call them your own
and, depending on the license used, disclose not only the changed, but
the source code to those receiving support from you for said changes.
That is, if you're at all serious about them and providing support too.

-- 
Austin Gonyou <[EMAIL PROTECTED]>
Coremetrics, Inc.

---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]


Re: [HACKERS] Using -Wshadow

2003-11-24 Thread Neil Conway
Tom Lane <[EMAIL PROTECTED]> writes:
> I wouldn't object to something that catches shadowings of parameters
> or local variables, but I think the flag as defined is not very
> useful.

On closer examination, that seems like a prescient comment. There are
about 1100 distinct warnings enabled by this flag. Of these, about 900
are caused by shadowed names from system headers: for example, using
'index' or 'shutdown' as the name of a function parameter. Note that a
single instance of shadowing in a header file generates warnings every
time that header file is included, so the number of actual places that
need to be changed should be smaller than 1100.

There are about 200 warnings that are not shadows of something from
the system headers. A fair number of these are also not very useful
(e.g. every variable named "length" triggers a warning, since that
shadows a function defined in pg_list.h), but there are also a fair
number of legitimately-shadowed local variables.

I think this leaves us with three options:

  (1) Do nothing

  (2) Enable -Wshadow for GCC, fix all the instances of the warning in
  the source tree.

  (3) Manually scan through the list of warnings and just submit
  patches for the legitimate instances of shadowing.

The problem with #2 is the large number of warnings induced by system
headers: other platforms / standard libraries may well cause
additional instances of shadowing, so it might take a little while to
track down all the spurious warnings. On the other hand, it would be
nice if we could just turn this on and then forget about it.

Any comments?

-Neil


---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
  joining column's datatypes do not match


Re: [HACKERS] regexp incompatibilites 7.3 and 7.4

2003-11-24 Thread Oleg Bartunov
On Mon, 24 Nov 2003, Tom Lane wrote:

> Oleg Bartunov <[EMAIL PROTECTED]> writes:
> > seems for regexp which works in 7.3 is failing in 7.4.
> > Is't possible to configure pgsql to be compatible with 7.3 regexp ?
>
> SET regex_flavor TO extended;

aha, thanks a lot

>
> > www=# select 'problem' ~ '^\\p';
> > ERROR:  invalid regular expression: invalid escape \ sequence
>
> I think, though, that this is telling you about a bug in your
> application.  You do realize that under extended regex rules there's
> no difference between that pattern and '^p' ?  Is that *really* what
> you want?


Actually, we have old application which uses perl function quotemeta()
which escaped any cyrillic characters. I used in example latin characters
for simplicity. I  have to use double backslash in psql only.



>
>   regards, tom lane
>

Regards,
Oleg
_
Oleg Bartunov, sci.researcher, hostmaster of AstroNet,
Sternberg Astronomical Institute, Moscow University (Russia)
Internet: [EMAIL PROTECTED], http://www.sai.msu.su/~megera/
phone: +007(095)939-16-83, +007(095)939-23-83

---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]


Re: [HACKERS] Updates for RPMS.

2003-11-24 Thread David Fetter
Lamar Owen <[EMAIL PROTECTED]> wrote:
> Sander Steffann has built Red Hat 6.2, 7.3, 9, and RHEL 2.1 RPM's
> for me, and I have uploaded them.  The release is different; 0.3PGDG
> and 0.4PGDG.  I will be looking at his spec file differences and
> updating the source RPM soon.  The binary RPM for Fedora will remain
> at 0.2PGDG for now.
> 
> If you have Fedora 1, Aurora 1.0, or Red Hat 8.0, you may continue
> using the 0.2PGDG set: for these distributions nothing has changed.
> The only change is in the building of the RPMs for Red Hat 6.2, 7.3,
> 9, and RHEL 2.1.

I just tried building 0.3PGDG on Redhat 9, and got:

# rpmbuild --rebuild postgresql-7.4-0.3PGDG.src.rpm
[snip]
checking krb5.h usability... no
checking krb5.h presence... no
checking for krb5.h... no
configure: error: header file  is required for Kerberos 5
error: Bad exit status from /var/tmp/rpm-tmp.97860 (%build)
[snip]

# uname -a
Linux fetter.org 2.4.20-8 #1 Thu Mar 13 17:54:28 EST 2003 i686 i686 i386 GNU/Linux

# locate krb5.h
/usr/kerberos/include/gssapi/gssapi_krb5.h
/usr/kerberos/include/krb5.h

Is there some way to tell the .spec file where to look for krb5.h?
Did I do something really boneheaded?

> A 1PGDG RPMset should come soon, once I see what Sander has done.

Woohoo!!! :)

Cheers,
D
-- 
David Fetter [EMAIL PROTECTED] http://fetter.org/
phone: +1 510 893 6100cell: +1 415 235 3778

One trend that bothers me is the glorification of stupidity, that the
media is reassuring people it's all right not to know anythingThat
to me is far more dangerous than a little pornography on the Internet.
Carl Sagan

---(end of broadcast)---
TIP 6: Have you searched our list archives?

   http://archives.postgresql.org


Re: [HACKERS] Using -Wshadow

2003-11-24 Thread Peter Eisentraut
Neil Conway writes:

> The problem with #2 is the large number of warnings induced by system
> headers: other platforms / standard libraries may well cause
> additional instances of shadowing, so it might take a little while to
> track down all the spurious warnings.

Yes, that's what I'm afraid of.  We might be chasing warnings forever.
I'm not sure what the point is anyway.  Shadowing is perfectly
well-defined and I've never heard of a real problem because of it.

-- 
Peter Eisentraut   [EMAIL PROTECTED]


---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])


Re: [HACKERS] Using -Wshadow

2003-11-24 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes:
> I'm not sure what the point is anyway.  Shadowing is perfectly
> well-defined and I've never heard of a real problem because of it.

Well, shadowing a formal parameter with a local variable is most likely
a mistake, and shadowing a local with a more-tightly-nested local is,
if not an outright mistake, certain to confuse future maintainers.
So I'd be in favor of getting rid of cases like that.

I can't get excited about forbidding shadowing of globals by locals,
though ... seems like that's practically giving up one of the
advantages of having a block-structured language in the first place.

BTW, what I find by experiment with gcc 2.95.3 is that
local-shadowing-formal is warned of just with -Wall, if the local is
declared at the function's outermost brace level, whether or not you
say -Wshadow.  So we already know we have none of those.

regards, tom lane

---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?

   http://www.postgresql.org/docs/faqs/FAQ.html


Re: [HACKERS] logical column position

2003-11-24 Thread Neil Conway
Robert Treat <[EMAIL PROTECTED]> writes:
> Seems merging the two would work... attlogpos, the attributes
> logical position.

Unless anyone has any further objections, I'll switch to using attlogpos.

-Neil


---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])


Re: [HACKERS] code question: rewriteDefine.c

2003-11-24 Thread Neil Conway
Tom Lane <[EMAIL PROTECTED]> writes:
> This is a backwards-compatibility hangover.

> But I'd not want to break it just because someone thinks the hack is
> ugly.  It was ugly from day one.

I agree it shouldn't be removed -- I was just curious to see what was
using it. It's certainly ugly, though.

I'll submit a patch documenting this.

-Neil


---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster


Re: [HACKERS] Build farm

2003-11-24 Thread Bruce Momjian

FYI, the HP testdrive farm, http://www.testdrive.hp.com, has shared
directories for most of the machines, meaning you can CVS update once
and telnet in to compile for each platform.

---

Andrew Dunstan wrote:
> Tom Lane wrote:
> 
> >
> >I think the main value of a build farm is that we'd get nearly immediate
> >feedback about the majority of simple porting problems.  Your previous
> >arguments that it wouldn't smoke everything out are certainly valid ---
> >but we wouldn't abandon the regression tests just because they don't
> >find everything.  Immediate feedback is good because a patch can be
> >fixed while it's still fresh in the author's mind.
> >
> 
> Yes, I seem to recall seeing several instances of things like "you mean 
> foonix version 97 1/2 has a bad frobnitz.h?" over the last 6 months. 
> Having that caught early is exactly the advantage, I believe.
> 
> >
> >I'm for it ...
> >  
> >
> 
> I'm working on it :-)
> 
> Regarding "make distcheck" that Peter suggested I use, unless I'm 
> mistaken it carefully does its own configure, thus ignoring the 
> configure options set in the original directory. Perhaps we need either 
> to have the distcheck target pick up all the --with/--without and 
> --enable/--disable options, or to have a similar target that does that.
> 
> Thoughts?
> 
> cheers
> 
> andrew
> 
> 
> 
> ---(end of broadcast)---
> TIP 7: don't forget to increase your free space map settings
> 

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 359-1001
  +  If your life is a hard drive, |  13 Roberts Road
  +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
  joining column's datatypes do not match


Re: [HACKERS] Commercial binary support?

2003-11-24 Thread Hans-Jürgen Schönig
Joshua D. Drake wrote:
Hello,

 I think what the person is looking for is:

 COMPANY PostgreSQL for Red Hat Enterprise 3.0.

 They probably have some commercial mandate that says that they have
to have a commercial company backing the product itself. This doesn't
work for most PostgreSQL companies because they back the "Open Source"
version of PostgreSQL.
 Where someone like Command Prompt, although we happily support the
Open Source version, we also sell Command Prompt PostgreSQL.
 It is purely a business thing, liability and the like.

Sincerely,

Joshua Drake


Hello

Tell me if I am significantly wrong but Command Prompt PostgreSQL is 
nothing more than "Open Source PostgreSQL" including some application 
server stuff, some propriertary PL/Perl || PL/PHP and not much more.

Your anwer to this statement will be: But it is supported.

Can you tell me a reason why somebody should use a closed source version 
of an Open Source product unless it contains some really significant 
improvement (say native Win32 or something like that)?

Can you tell me ONE reason why this does not work for other PostgreSQL 
companies such as `eval LONG LIST`?
Personally I think everybody can have its business strategy but what 
REALLY sets me up is that this mail seems to mean that Command Prompt is 
the only support company around which is actually WRONG!

In my opinion everybody who has enough skills can do this kind of job. 
Being a support company has nothing to do with making a good Open Source 
product a closed source product.
In my opinion giving something a new name and hiding away some code does 
not mean commercial backing and it does not mean being the god of all 
support companies.

	Regards,

		Hans

--
Cybertec Geschwinde u Schoenig
Ludo-Hartmannplatz 1/14, A-1160 Vienna, Austria
Tel: +43/2952/30706 or +43/660/816 40 77
www.cybertec.at, www.postgresql.at, kernel.cybertec.at


---(end of broadcast)---
TIP 7: don't forget to increase your free space map settings


Re: [HACKERS] ObjectWeb/Clustered JDBC

2003-11-24 Thread Hans-Jürgen Schönig
Peter Eisentraut wrote:
I was at the ObjectWeb Conference today; ObjectWeb
(http://www.objectweb.org) being a consortium that has amassed quite an
impressive array of open-source, Java-based middleware under their
umbrella, including for instance our old friend Enhydra.  And they
regularly kept mentioning PostgreSQL in their presentations.
To those that are interested in distributed transactions/two-phase commit,
I recommend taking a look at Clustered JDBC
(http://c-jdbc.objectweb.org/).  While this is not exactly the same thing,
it looks to be a pretty neat solution for a similar class of applications.
In particular, it provides redundancy, load balancing, caching, and even
database independence.


It is indeed a nice solution but it is far from ready yet.
Especially the disaster recovery mechanism and things such as adding new 
masters need some more work.
What I really miss is "DECLARE CURSOR". Maybe it will be in there some 
day :).
However, we have done some real testing with sync replication (4 x pg, 1 
x oracle). It performed surprisingly well (the JDBC part, not the Oracle 
one ;) ).
Maybe this will be something really useful within the next few months.

	Cheers,

		Hans

--
Cybertec Geschwinde u Schoenig
Ludo-Hartmannplatz 1/14, A-1160 Vienna, Austria
Tel: +43/2952/30706 or +43/660/816 40 77
www.cybertec.at, www.postgresql.at, kernel.cybertec.at


---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?
  http://www.postgresql.org/docs/faqs/FAQ.html


Re: [HACKERS] [7.4] statistics collector: Protocol not supported

2003-11-24 Thread Bruce Momjian
Tom Lane wrote:
> "Marc G. Fournier" <[EMAIL PROTECTED]> writes:
> > Is it easy to do a quick message change to state that it was the IPv6
> > socket that failed?
> 
> I deliberately did not do that because we were well past error message
> freeze for 7.4, but we certainly should fix it for 7.5.

Yes, I am unsure why the mention of IPv6 was removed from the original
patch I submitted.  Does anyone remember?

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 359-1001
  +  If your life is a hard drive, |  13 Roberts Road
  +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
  joining column's datatypes do not match


Re: [HACKERS] Build farm

2003-11-24 Thread Jim C. Nasby
On Wed, Nov 19, 2003 at 04:34:27PM +0100, Peter Eisentraut wrote:
> Hence the open-source community approach.  Closed-source development teams
> can do all the above, with great effort.  But by throwing out the code and
> have real people test them on real systems with real applications, you can
> do much better.
 
Would it be reasonable to promote users testing daily snapshots with
popular applications? I'm guessing there's not many applications that
have automated test frameworks, but any that do would theoretically
provide another good test of PGSQL changes.
-- 
Jim C. Nasby, Database Consultant  [EMAIL PROTECTED]
Member: Triangle Fraternity, Sports Car Club of America
Give your computer some brain candy! www.distributed.net Team #1828

Windows: "Where do you want to go today?"
Linux: "Where do you want to go tomorrow?"
FreeBSD: "Are you guys coming, or what?"

---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]


Re: [HACKERS] Build farm

2003-11-24 Thread Christopher Kings-Lynne
Would it be reasonable to promote users testing daily snapshots with
popular applications? I'm guessing there's not many applications that
have automated test frameworks, but any that do would theoretically
provide another good test of PGSQL changes.
May I quote Joel on Software here?

http://www.joelonsoftware.com/articles/fog43.html

The Joel Test

   1. Do you use source control?
   2. Can you make a build in one step?
   3. Do you make daily builds?
   4. Do you have a bug database?
   5. Do you fix bugs before writing new code?
   6. Do you have an up-to-date schedule?
   7. Do you have a spec?
   8. Do programmers have quiet working conditions?
   9. Do you use the best tools money can buy?
  10. Do you have testers?
  11. Do new candidates write code during their interview?
  12. Do you do hallway usability testing?
"The neat thing about The Joel Test is that it's easy to get a quick yes 
or no to each question. You don't have to figure out 
lines-of-code-per-day or average-bugs-per-inflection-point. Give your 
team 1 point for each "yes" answer. The bummer about The Joel Test is 
that you really shouldn't use it to make sure that your nuclear power 
plant software is safe.

A score of 12 is perfect, 11 is tolerable, but 10 or lower and you've 
got serious problems. The truth is that most software organizations are 
running with a score of 2 or 3, and they need serious help, because 
companies like Microsoft run at 12 full-time. "

Not everything there applies to us, of course.

Chris



---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
 subscribe-nomail command to [EMAIL PROTECTED] so that your
 message can get through to the mailing list cleanly


Re: [HACKERS] Release cycle length

2003-11-24 Thread Jim C. Nasby
On Fri, Nov 21, 2003 at 01:32:38PM -0500, Jan Wieck wrote:
> bootstrap mode to apply the changes, could be an idea to think of. It 
> would still require some downtime, but nobody can avoid that when 
> replacing the postgres binaries anyway, so that's not a real issue. As 
> long as it eliminates dump, initdb, reload it will be acceptable.
 
Has anyone looked at using replication as a migration method? If
replication can be setup in such a way that you can replicate from an
old version to a new version, you can use that to build the new version
of the database on a seperate machine/instance while the old version is
still live. With some sophisticated middleware, you could theoretically
migrate without any downtime.
-- 
Jim C. Nasby, Database Consultant  [EMAIL PROTECTED]
Member: Triangle Fraternity, Sports Car Club of America
Give your computer some brain candy! www.distributed.net Team #1828

Windows: "Where do you want to go today?"
Linux: "Where do you want to go tomorrow?"
FreeBSD: "Are you guys coming, or what?"

---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
  joining column's datatypes do not match


Re: [HACKERS] [7.4] statistics collector: Protocol not supported

2003-11-24 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes:
> Yes, I am unsure why the mention of IPv6 was removed from the original
> patch I submitted.  Does anyone remember?

You sure you aren't confusing this code with the listen-socket-opening
code over in backend/libpq/ ?

The libpq code identifies the socket type (and I think we should just
borrow that logic for pgstat.c) but I don't believe anyone proposed
making pgstat do so, because up till this recent patch it wouldn't try
more than one socket type anyway.

regards, tom lane

---(end of broadcast)---
TIP 6: Have you searched our list archives?

   http://archives.postgresql.org


Re: [HACKERS] [7.4] statistics collector: Protocol not supported

2003-11-24 Thread Bruce Momjian
Tom Lane wrote:
> Bruce Momjian <[EMAIL PROTECTED]> writes:
> > Yes, I am unsure why the mention of IPv6 was removed from the original
> > patch I submitted.  Does anyone remember?
> 
> You sure you aren't confusing this code with the listen-socket-opening
> code over in backend/libpq/ ?
> 
> The libpq code identifies the socket type (and I think we should just
> borrow that logic for pgstat.c) but I don't believe anyone proposed
> making pgstat do so, because up till this recent patch it wouldn't try
> more than one socket type anyway.

Oh, yes confused.  I never considered the stats listener message before.

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 359-1001
  +  If your life is a hard drive, |  13 Roberts Road
  +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])


Re: [HACKERS] Release cycle length

2003-11-24 Thread Christopher Browne
Quoth [EMAIL PROTECTED] ("Jim C. Nasby"):
> On Fri, Nov 21, 2003 at 01:32:38PM -0500, Jan Wieck wrote:
>> bootstrap mode to apply the changes, could be an idea to think of. It 
>> would still require some downtime, but nobody can avoid that when 
>> replacing the postgres binaries anyway, so that's not a real issue. As 
>> long as it eliminates dump, initdb, reload it will be acceptable.
>  
> Has anyone looked at using replication as a migration method? If
> replication can be setup in such a way that you can replicate from an
> old version to a new version, you can use that to build the new version
> of the database on a seperate machine/instance while the old version is
> still live. With some sophisticated middleware, you could theoretically
> migrate without any downtime.

The idea has indeed been "looked at," and seems pretty feasible.

It would certainly take some sophisticated middleware to totally evade
downtime.  But replicating from "old version" to "new version" does
have the merit of keeping the downtime to fairly much a minimum.
-- 
wm(X,Y):-write(X),write('@'),write(Y). wm('cbbrowne','cbbrowne.com').
http://www3.sympatico.ca/cbbrowne/x.html
:FATAL ERROR -- VECTOR OUT OF HILBERT SPACE

---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
  subscribe-nomail command to [EMAIL PROTECTED] so that your
  message can get through to the mailing list cleanly


Re: [HACKERS] Build farm

2003-11-24 Thread Peter Eisentraut
Bruce Momjian writes:

> FYI, the HP testdrive farm, http://www.testdrive.hp.com, has shared
> directories for most of the machines, meaning you can CVS update once
> and telnet in to compile for each platform.

Except that you can't open connections to the outside from these machines.

-- 
Peter Eisentraut   [EMAIL PROTECTED]


---(end of broadcast)---
TIP 8: explain analyze is your friend


[HACKERS] Updates for RPMS.

2003-11-24 Thread Lamar Owen
Sander Steffann has built Red Hat 6.2, 7.3, 9, and RHEL 2.1 RPM's for me, and 
I have uploaded them.  The release is different; 0.3PGDG and 0.4PGDG.  I will 
be looking at his spec file differences and updating the source RPM soon.  
The binary RPM for Fedora will remain at 0.2PGDG for now.

If you have Fedora 1, Aurora 1.0, or Red Hat 8.0, you may continue using the 
0.2PGDG set: for these distributions nothing has changed.  The only change is 
in the building of the RPMs for Red Hat 6.2, 7.3, 9, and RHEL 2.1.

A 1PGDG RPMset should come soon, once I see what Sander has done.  This will 
just be spec file changes, probably, unless another bug appears in the 
initscript.
-- 
Lamar Owen
Director of Information Technology
Pisgah Astronomical Research Institute
1 PARI Drive
Rosman, NC  28772
(828)862-5554
www.pari.edu


---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]