Re: [HACKERS] New tzdata available

2007-11-09 Thread Zdenek Kotala
Tom Lane wrote: Magnus Hagander [EMAIL PROTECTED] writes: On Fri, 2007-11-09 at 02:26 -0500, Tom Lane wrote: Plan B would be to take out contracts on all the banana-republic politicians who think that changing DST laws with a month's notice is a pleasant pastime. I fear we lack the resources

Re: [HACKERS] How to determine if psql returns ZERO to the shell and finished successfully?

2007-11-09 Thread Jorgen Austvik - Sun Norway
Tommy wrote: How exactly can I check to see if psql returns ZERO to the shell? What do I test for? If(Psql.exe)? or is there a variable I can check to see if it has been set? If you are running Delphi on Windows (the MsgBox makes me guess so), take a look here:

Re: [HACKERS] New tzdata available

2007-11-09 Thread Magnus Hagander
On Fri, 2007-11-09 at 02:56 -0500, Tom Lane wrote: Magnus Hagander [EMAIL PROTECTED] writes: On Fri, 2007-11-09 at 02:26 -0500, Tom Lane wrote: Plan B would be to take out contracts on all the banana-republic politicians who think that changing DST laws with a month's notice is a

Re: [HACKERS] [PERFORM] Estimation problem with a LIKE clause containing a /

2007-11-09 Thread Gregory Stark
Tom Lane [EMAIL PROTECTED] writes: This rule works for all the locales I have installed ... but I don't have any Far Eastern locales installed. Also, my test cases are only covering ASCII characters, and I believe many locales have some non-ASCII letters that sort after 'Z'. I'm not sure

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Heikki Linnakangas
Alvaro Herrera wrote: Simon Riggs wrote: Presumably we would not store an FSM for small tables? On the basis that the purpose of the FSM is to save on pointless I/O there must be a size of table below which an FSM is just overhead. Hmm, do you mean that we would open and verify every page of

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Simon Riggs
On Thu, 2007-11-08 at 21:50 -0300, Alvaro Herrera wrote: Simon Riggs wrote: Presumably we would not store an FSM for small tables? On the basis that the purpose of the FSM is to save on pointless I/O there must be a size of table below which an FSM is just overhead. Hmm, do you mean

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Heikki Linnakangas
Simon Riggs wrote: On Thu, 2007-11-08 at 23:04 +, Gregory Stark wrote: Simon Riggs [EMAIL PROTECTED] writes: The pages might well be in cache, so the file location might well be irrelevant from an I/O perspective. Maybe. The nth page solution allows the FSM block to be easily located

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Heikki Linnakangas
Simon Riggs wrote: On Thu, 2007-11-08 at 21:50 -0300, Alvaro Herrera wrote: Simon Riggs wrote: Presumably we would not store an FSM for small tables? On the basis that the purpose of the FSM is to save on pointless I/O there must be a size of table below which an FSM is just overhead. Hmm,

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Simon Riggs
On Fri, 2007-11-09 at 09:39 +, Heikki Linnakangas wrote: Simon Riggs wrote: On Thu, 2007-11-08 at 23:04 +, Gregory Stark wrote: Simon Riggs [EMAIL PROTECTED] writes: The pages might well be in cache, so the file location might well be irrelevant from an I/O perspective. Maybe.

Re: [HACKERS] New tzdata available

2007-11-09 Thread Gregory Stark
Magnus Hagander [EMAIL PROTECTED] writes: On Fri, 2007-11-09 at 02:56 -0500, Tom Lane wrote: Be fair --- the USA did give us a couple years' notice. Not for the latest changes, IIRC. It didn't match my recollection either. But apparently Tom is almost right. The Energy Policy Act of 2005

Re: [HACKERS] New tzdata available

2007-11-09 Thread Magnus Hagander
On Fri, 2007-11-09 at 10:04 +, Gregory Stark wrote: Magnus Hagander [EMAIL PROTECTED] writes: On Fri, 2007-11-09 at 02:56 -0500, Tom Lane wrote: Be fair --- the USA did give us a couple years' notice. Not for the latest changes, IIRC. It didn't match my recollection either.

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Simon Riggs
On Fri, 2007-11-09 at 09:23 +, Heikki Linnakangas wrote: Alvaro Herrera wrote: Simon Riggs wrote: Presumably we would not store an FSM for small tables? On the basis that the purpose of the FSM is to save on pointless I/O there must be a size of table below which an FSM is just

[HACKERS] Feature request concerning postmaster log file.

2007-11-09 Thread David BOURIAUD
Hi to all, Could it be possible to have informations about who do what on any tablespace or database logged in separate files, as samba does. I don't think that it should be the default way, since the way events are logged by now seems to please all users, but I'd think that a run-time option

Re: [HACKERS] Feature request concerning postmaster log file.

2007-11-09 Thread Zdenek Kotala
David BOURIAUD wrote: if the run-time option is chosen, any message issued by any command, from connexion to all sql commands launched in any way by a user should go in a separate log file, that could be named log.username for example. You can enable logging user name into postgres log and

Re: [HACKERS] New tzdata available

2007-11-09 Thread Alvaro Herrera
Magnus Hagander wrote: Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: Zdenek Kotala wrote: I think we need some different mechanism how to deliver timezone updated. Even when the system TZ is not used, we could deliver our zic executable (pgzic?) and let the user drop the

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Alvaro Herrera
Heikki Linnakangas wrote: - We need a solution for the indexes as well. A separate file would fit nicely for them, though the contents would be different because for indexes we only care if a page is unused or not. FWIW I think it's worth considering that we may be interested in keeping

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Alvaro Herrera
Heikki Linnakangas wrote: Alvaro Herrera wrote: Simon Riggs wrote: Presumably we would not store an FSM for small tables? On the basis that the purpose of the FSM is to save on pointless I/O there must be a size of table below which an FSM is just overhead. Hmm, do you mean that we would

Re: [HACKERS] New tzdata available

2007-11-09 Thread Magnus Hagander
On Fri, 2007-11-09 at 09:25 -0300, Alvaro Herrera wrote: Magnus Hagander wrote: Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: Zdenek Kotala wrote: I think we need some different mechanism how to deliver timezone updated. Even when the system TZ is not used, we

Re: [HACKERS] New tzdata available

2007-11-09 Thread Zdenek Kotala
Alvaro Herrera wrote: I think the first step is to install the zic binary along the rest of the stuff, so that a user without the source tree can compile the tzdata package. Unless the compiled representation is portable, which I kinda doubt? Maybe wild idea, what's about use buildfarm to

Re: [HACKERS] New tzdata available

2007-11-09 Thread Zdenek Kotala
Magnus Hagander wrote: On Fri, 2007-11-09 at 09:25 -0300, Alvaro Herrera wrote: Magnus Hagander wrote: Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: Zdenek Kotala wrote: I think we need some different mechanism how to deliver timezone updated. Even when the system TZ is not

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Heikki Linnakangas
Alvaro Herrera wrote: One idea is to have the first FSM page be movable, and create it by extending the table when as soon as it's first needed (this would be the first vacuum that needs to record free space on the table). The page number used is recorded in the relcache entry (and pg_class).

Re: [HACKERS] New tzdata available

2007-11-09 Thread Magnus Hagander
On Fri, 2007-11-09 at 14:23 +0100, Zdenek Kotala wrote: Magnus Hagander wrote: On Fri, 2007-11-09 at 09:25 -0300, Alvaro Herrera wrote: Magnus Hagander wrote: Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: Zdenek Kotala wrote: I think we need some different mechanism how to

Re: [HACKERS] Free Space Map thoughts

2007-11-09 Thread Simon Riggs
On Fri, 2007-11-09 at 13:27 +, Heikki Linnakangas wrote: Alvaro Herrera wrote: One idea is to have the first FSM page be movable, and create it by extending the table when as soon as it's first needed (this would be the first vacuum that needs to record free space on the table). The

Re: [HACKERS] New tzdata available

2007-11-09 Thread Andrew Dunstan
Zdenek Kotala wrote: Alvaro Herrera wrote: I think the first step is to install the zic binary along the rest of the stuff, so that a user without the source tree can compile the tzdata package. Unless the compiled representation is portable, which I kinda doubt? Maybe wild idea, what's

Re: [HACKERS] New tzdata available

2007-11-09 Thread Zdenek Kotala
Andrew Dunstan wrote: Zdenek Kotala wrote: Alvaro Herrera wrote: I think the first step is to install the zic binary along the rest of the stuff, so that a user without the source tree can compile the tzdata package. Unless the compiled representation is portable, which I kinda doubt?

Re: [HACKERS] Feature request concerning postmaster log file.

2007-11-09 Thread David BOURIAUD
Le vendredi 9 novembre 2007, vous avez écrit : David BOURIAUD wrote: if the run-time option is chosen, any message issued by any command, from connexion to all sql commands launched in any way by a user should go in a separate log file, that could be named log.username for example. You

Re: [HACKERS] Feature request concerning postmaster log file.

2007-11-09 Thread Heikki Linnakangas
David BOURIAUD wrote: Le vendredi 9 novembre 2007, vous avez écrit : David BOURIAUD wrote: if the run-time option is chosen, any message issued by any command, from connexion to all sql commands launched in any way by a user should go in a separate log file, that could be named log.username

Re: [HACKERS] Feature request concerning postmaster log file.

2007-11-09 Thread Andrew Dunstan
David BOURIAUD wrote: Le vendredi 9 novembre 2007, vous avez écrit : David BOURIAUD wrote: if the run-time option is chosen, any message issued by any command, from connexion to all sql commands launched in any way by a user should go in a separate log file, that could be named

Re: [HACKERS] Test lab

2007-11-09 Thread Greg Smith
On Sun, 4 Nov 2007, Stefan Kaltenbrunner wrote: I never got the database tests in SysBench to produce useful results [because of deadlocks] hmm I have not seen that and the recent freebsd related scalability benchmarks(http://people.freebsd.org/~kris/scaling/) seem to indicate that it seems

Re: [HACKERS] Feature request concerning postmaster log file.

2007-11-09 Thread Zdenek Kotala
Heikki Linnakangas wrote: David BOURIAUD wrote: Le vendredi 9 novembre 2007, vous avez écrit : David BOURIAUD wrote: if the run-time option is chosen, any message issued by any command, from connexion to all sql commands launched in any way by a user should go in a separate log file, that

Re: [HACKERS] Feature request concerning postmaster log file.

2007-11-09 Thread Greg Smith
On Fri, 9 Nov 2007, David BOURIAUD wrote: using a text utility like grep is not suitable. I think of this when you get a many hundreds of MB logfile at least, or when you need to track commands made by one peculiar user in real-time. If your problem is that individual log files are too big

Re: [HACKERS] New tzdata available

2007-11-09 Thread Tom Lane
Zdenek Kotala [EMAIL PROTECTED] writes: Another interesting questions are what postgres does when timezone files are changed? Does it need SIGHUP to invoke rereading? What is impact on current running transaction when tz file is changed? This falls into the category of get a life. There is

Re: [HACKERS] [PERFORM] Estimation problem with a LIKE clause containing a /

2007-11-09 Thread Tom Lane
Gregory Stark [EMAIL PROTECTED] writes: Could we not use the bogus range to calculate the histogram estimate but apply the LIKE pattern directly to the most-frequent-values instead of applying the bogus range? Or would that be too much code re-organization for now? We have already done that

Re: [HACKERS] [PERFORM] Estimation problem with a LIKE clause containing a /

2007-11-09 Thread Guillaume Smet
On Nov 9, 2007 5:33 PM, Tom Lane [EMAIL PROTECTED] wrote: he's got no MCVs, presumably because the field is unique. It is. The ancestors field contains the current folder itself so the id of the folder (which is the primary key) is in it. -- Guillaume ---(end of

Re: [HACKERS] New tzdata available

2007-11-09 Thread Tom Lane
Alvaro Herrera [EMAIL PROTECTED] writes: I think the first step is to install the zic binary along the rest of the stuff, so that a user without the source tree can compile the tzdata package. Unless the compiled representation is portable, which I kinda doubt? Actually, it is. In fact,

[HACKERS] Re: [COMMITTERS] pgsql: - Add check of already changed page while replay WAL.

2007-11-09 Thread Robert Treat
On Monday 29 October 2007 15:27, Teodor Sigaev wrote: Log Message: --- - Add check of already changed page while replay WAL. This touches only ginRedoInsert(), because other ginRedo* functions rewrite whole page or make changes which could be applied several times without consistent's

Re: [HACKERS] [PATCHES] Fix pg_dump dependency on postgres.h

2007-11-09 Thread Zdenek Kotala
Zdenek Kotala wrote: Attached patch removes pg_dump dependency on postgres.h. The main reason for that was discussed there: http://archives.postgresql.org/pgsql-hackers/2007-10/msg01261.php I found two problems there. One is that I forgot postgres.h include in common.c. it is easy to fix.

Re: [HACKERS] New tzdata available

2007-11-09 Thread Zdenek Kotala
Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: I think the first step is to install the zic binary along the rest of the stuff, so that a user without the source tree can compile the tzdata package. Unless the compiled representation is portable, which I kinda doubt? Actually, it

Re: [HACKERS] krb_match_realm patch

2007-11-09 Thread Magnus Hagander
Stephen Frost wrote: Greetings, Regarding Magnus' patch for matching against the Kerberos realm- I'd see it as much more useful as a multi-value configuration option. Perhaps 'krb_alt_realms' or 'krb_realms'. This would look like: Match against one, and only one, realm (does not

Re: [HACKERS] Throw error and ErrorContext question.

2007-11-09 Thread Gevik Babakhani
Hello Tom, I have a solution by adding two parameters (skip_error and skipped_sqlerrorcode) to qualifiedNameToVar,transformWholeRowRef,addImplicitRTE,warnAutoRange. It still needs a bit of refining before I can send the patch for full review. When in context of parsing functions for

Re: [HACKERS] New tzdata available

2007-11-09 Thread Alvaro Herrera
Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: I think the first step is to install the zic binary along the rest of the stuff, so that a user without the source tree can compile the tzdata package. Unless the compiled representation is portable, which I kinda doubt?

[HACKERS] plperl.dll error from create langauge plperl (XP Pro 64 bit)

2007-11-09 Thread Doug Knight
All, I am building an XP Pro 64 bit system, where I have installed the latest PostgreSQL binary distribution (8.2.5-1). Everything loaded fine, I have postgres up and running as a service, installed ActiveTcl and ActivePerl, enabled PostGIS, etc. I can do the CREATE LANGUAGE 'pgtcl' successfully,

Re: [HACKERS] plperl.dll error from create langauge plperl (XP Pro 64 bit)

2007-11-09 Thread Andrew Dunstan
Doug Knight wrote: All, I am building an XP Pro 64 bit system, where I have installed the latest PostgreSQL binary distribution (8.2.5-1). Everything loaded fine, I have postgres up and running as a service, installed ActiveTcl and ActivePerl, enabled PostGIS, etc. I can do the CREATE

Re: [HACKERS] plperl.dll error from create langauge plperl (XP Pro 64 bit)

2007-11-09 Thread Doug Knight
Hi Andrew, The ActivePerl is 64 bit. Funny how it didn't affect the ActiveTcl and pltcl load. Everything else seems to work fine, just loading the perl lib. Doug On Fri, 2007-11-09 at 15:35 -0500, Andrew Dunstan wrote: Doug Knight wrote: All, I am building an XP Pro 64 bit system, where I

Re: [HACKERS] [PERFORM] Estimation problem with a LIKE clause containing a /

2007-11-09 Thread Guillaume Smet
Tom, Just to confirm you that your last commit fixed the problem: lbo=# explain analyze select * from cms_items where ancestors LIKE '1062/%'; QUERY PLAN

[HACKERS] Latest xml patch breaks some of the buildfarm

2007-11-09 Thread Tom Lane
Some but not all buildfarm members are showing unexpected xml regression test output: *** ./expected/xml.out Fri Nov 9 11:44:01 2007 --- ./results/xml.out Fri Nov 9 12:54:10 2007 *** *** 184,189 --- 184,191 ERROR: invalid XML processing instruction DETAIL: XML

[HACKERS] last note to rewrite function

2007-11-09 Thread Pavel Stehule
Hello ts_rewrite(ARRAY[query TSQUERY, target TSQUERY, sample TSQUERY]) returns TSQUERY why we use array? Multicolumn aggregate function is maybe more natural? and we can this? It is too late for change? Regards Pavel Stehule ---(end of

[HACKERS] dump order for index defs

2007-11-09 Thread Andrew Dunstan
I have just been noticing that pg_dump outputs index definitions sorted by index name (within a given schema). Would it not be better to sort by indexed_relation_name, index_name so that we get some benefit from caching the table when building multiple indexes on the same table? cheers

Re: [HACKERS] plperl.dll error from create langauge plperl (XP Pro 64 bit)

2007-11-09 Thread Magnus Hagander
Doug Knight wrote: Doug On Fri, 2007-11-09 at 15:35 -0500, Andrew Dunstan wrote: Doug Knight wrote: All, I am building an XP Pro 64 bit system, where I have installed the latest PostgreSQL binary distribution (8.2.5-1). Everything loaded fine, I have postgres up and running as a

Re: [HACKERS] fulltext parser strange behave

2007-11-09 Thread Tom Lane
Andrew Dunstan [EMAIL PROTECTED] writes: I've just been looking at the state machine in wparser_def.c. I think the processing for entities is also a few bob short in the pound. It recognises decimal numeric character references, but nor hexadecimal numeric character references. That's

Re: [HACKERS] last note to rewrite function

2007-11-09 Thread Tom Lane
Pavel Stehule [EMAIL PROTECTED] writes: ts_rewrite(ARRAY[query TSQUERY, target TSQUERY, sample TSQUERY]) returns TSQUERY why we use array? That function is gone. regards, tom lane ---(end of broadcast)--- TIP 4: Have

Re: [HACKERS] [GENERAL] Is query a reserved word in 8.3 plpgsql?

2007-11-09 Thread Tom Lane
Todd A. Cook [EMAIL PROTECTED] writes: I saw the item in the release notes about the new return query syntax in pl/pgsql, but I didn't see any note about query being reserved now. Perhaps an explicit mention should be added? Yeah, I got burnt by that too. I have a bad feeling that that

Re: [HACKERS] Segmentation fault using digest from pg_crypto

2007-11-09 Thread Marko Kreen
On 11/7/07, Bruce Momjian [EMAIL PROTECTED] wrote: OK, should we add a mention in the 8.2.6 release notes or put it in the 8. notes and figure if someone is upgrading they will read the 8.2 notes? What would the description be? Note about pgcrypto - the functions were made STRICT in 8.1 and

Re: [HACKERS] [GENERAL] Is query a reserved word in 8.3 plpgsql?

2007-11-09 Thread Scott Marlowe
On Nov 9, 2007 5:14 PM, Tom Lane [EMAIL PROTECTED] wrote: Todd A. Cook [EMAIL PROTECTED] writes: I saw the item in the release notes about the new return query syntax in pl/pgsql, but I didn't see any note about query being reserved now. Perhaps an explicit mention should be added? Yeah,

Re: [HACKERS] Segmentation fault using digest from pg_crypto

2007-11-09 Thread Bruce Momjian
Marko Kreen wrote: On 11/7/07, Bruce Momjian [EMAIL PROTECTED] wrote: OK, should we add a mention in the 8.2.6 release notes or put it in the 8. notes and figure if someone is upgrading they will read the 8.2 notes? What would the description be? Note about pgcrypto - the functions

[HACKERS] plpgsql: another new reserved word

2007-11-09 Thread Marko Kreen
I stumbled on another gotcha in 8.3's plpgsql: create or replace function foobar() returns text as $$ declare foobar text; begin return 'ok'; end; $$ language plpgsql; Results in error: ERROR: syntax error at or near foobar LINE 3: foobar text; ^ If this is intentional,

Re: [HACKERS] Segmentation fault using digest from pg_crypto

2007-11-09 Thread Marko Kreen
On 11/10/07, Bruce Momjian [EMAIL PROTECTED] wrote: OK, first question. How would someone have the 8.0 signatures in 8.2? Don't they reinstall pgcrypto for every major release? Why reinstall if the functions come from dump? At least in skype we stumbled on the problem. But if the reinstall

Re: [HACKERS] plpgsql: another new reserved word

2007-11-09 Thread Pavel Stehule
On 10/11/2007, Marko Kreen [EMAIL PROTECTED] wrote: I stumbled on another gotcha in 8.3's plpgsql: create or replace function foobar() returns text as $$ declare foobar text; begin return 'ok'; end; $$ language plpgsql; Results in error: ERROR: syntax error at or near foobar

Re: [HACKERS] last note to rewrite function

2007-11-09 Thread Pavel Stehule
On 09/11/2007, Tom Lane [EMAIL PROTECTED] wrote: Pavel Stehule [EMAIL PROTECTED] writes: ts_rewrite(ARRAY[query TSQUERY, target TSQUERY, sample TSQUERY]) returns TSQUERY why we use array? That function is gone. regards, tom lane ook, sure Pavel

Re: [HACKERS] Segmentation fault using digest from pg_crypto

2007-11-09 Thread Tom Lane
Marko Kreen [EMAIL PROTECTED] writes: On 11/10/07, Bruce Momjian [EMAIL PROTECTED] wrote: OK, first question. How would someone have the 8.0 signatures in 8.2? Don't they reinstall pgcrypto for every major release? Why reinstall if the functions come from dump? At least in skype we

Re: [HACKERS] [GENERAL] Is query a reserved word in 8.3 plpgsql?

2007-11-09 Thread Tom Lane
Scott Marlowe [EMAIL PROTECTED] writes: On Nov 9, 2007 5:14 PM, Tom Lane [EMAIL PROTECTED] wrote: [ thinks for a bit... ] It might be possible to get rid of the keyword and have RETURN QUERY be recognized by an ad-hoc strcmp test, much like the various direction keywords in FETCH have been

Re: [HACKERS] Segmentation fault using digest from pg_crypto

2007-11-09 Thread Bruce Momjian
Marko Kreen wrote: On 11/10/07, Bruce Momjian [EMAIL PROTECTED] wrote: OK, first question. How would someone have the 8.0 signatures in 8.2? Don't they reinstall pgcrypto for every major release? Why reinstall if the functions come from dump? At least in skype we stumbled on the

Re: [HACKERS] Segmentation fault using digest from pg_crypto

2007-11-09 Thread Bruce Momjian
Tom Lane wrote: Marko Kreen [EMAIL PROTECTED] writes: On 11/10/07, Bruce Momjian [EMAIL PROTECTED] wrote: OK, first question. How would someone have the 8.0 signatures in 8.2? Don't they reinstall pgcrypto for every major release? Why reinstall if the functions come from dump? At

[HACKERS] autovacuum_freeze_max_age

2007-11-09 Thread Jacques Caron
Hi, I was wondering why autovacuum_freeze_max_age actually can't be set at runtime... guc.c points to varsup.c which says: * Note: autovacuum_freeze_max_age is a PGC_POSTMASTER parameter so that * we don't have to worry about dealing with on-the-fly changes in its

[HACKERS] Need for advice and direction (again)

2007-11-09 Thread Gevik Babakhani
Hello Tom, I would like to know your opinion about the way we should refer to composite type params in functions. For example: CREATE TABLE emp ( nametext, salary numeric, age integer, cubicle point ); CREATE FUNCTION double_salary(emp) RETURNS numeric

Re: [HACKERS] Segmentation fault using digest from pg_crypto

2007-11-09 Thread Tom Lane
Bruce Momjian [EMAIL PROTECTED] writes: Tom Lane wrote: If you don't re-run a contrib module's sql script then you don't get any new functions that may have been added to the module. So I think the real issue here is that we ought to deprecate the idea of skipping that step, period. The

Re: [HACKERS] plpgsql: another new reserved word

2007-11-09 Thread Tom Lane
Pavel Stehule [EMAIL PROTECTED] writes: On 10/11/2007, Marko Kreen [EMAIL PROTECTED] wrote: I stumbled on another gotcha in 8.3's plpgsql: It's label for function's parameters. But now that you mention it, that behavior is a little bit ugly. I believe it's a pretty common practice to use a

Re: [HACKERS] [GENERAL] Is query a reserved word in 8.3 plpgsql?

2007-11-09 Thread Scott Marlowe
On Nov 9, 2007 6:07 PM, Tom Lane [EMAIL PROTECTED] wrote: Scott Marlowe [EMAIL PROTECTED] writes: On Nov 9, 2007 5:14 PM, Tom Lane [EMAIL PROTECTED] wrote: [ thinks for a bit... ] It might be possible to get rid of the keyword and have RETURN QUERY be recognized by an ad-hoc strcmp test,

Re: [HACKERS] autovacuum_freeze_max_age

2007-11-09 Thread Tom Lane
Jacques Caron [EMAIL PROTECTED] writes: I was wondering why autovacuum_freeze_max_age actually can't be set at runtime... guc.c points to varsup.c which says: Hmm. The original worry was that different uses might be out of sync, but right offhand it doesn't look like anything catastrophic

Re: [HACKERS] Need for advice and direction (again)

2007-11-09 Thread Tom Lane
Gevik Babakhani [EMAIL PROTECTED] writes: How should we refer to emp in the following example. CREATE FUNCTION double_salary(PARAM1 emp) RETURNS numeric AS $$ -- At this moment PARAM1.salary will fail because PARAM1 -- is compared to the name of this function SELECT

Re: [HACKERS] [BUGS] Nasty tsvector can make dumps unrestorable

2007-11-09 Thread Bruce Momjian
Tom Lane wrote: Stuart Bishop [EMAIL PROTECTED] writes: The attached script creates a tsvector with a value that can be dumped using pg_dump, but not loaded again using pg_restore. This causes restores of a dump containing this value to fail. Hmm, sorta looks like tsvectorout should be

Re: [HACKERS] [BUGS] Nasty tsvector can make dumps unrestorable

2007-11-09 Thread Andrew Dunstan
Bruce Momjian wrote: However, I am still unclear if the dump code is correct because I don't see the backslash preserved in \\'' cases, just cases: test= CREATE TABLE Foo(bar tsvector); CREATE test= INSERT INTO Foo(bar) VALUES (E'\\''x'); INSERT 0 1

Re: [HACKERS] [BUGS] Nasty tsvector can make dumps unrestorable

2007-11-09 Thread Bruce Momjian
Andrew Dunstan wrote: While the COPY will load into the table, this doesn't: test= INSERT INTO Foo(bar) VALUES (E'x'); ERROR: syntax error in tsvector: ''x I am confused. These two are not equivalent. What happens if you try this? INSERT INTO Foo(bar)

[HACKERS] data access automatic filter

2007-11-09 Thread [EMAIL PROTECTED]
Hi, I'm evaluating the option of write a PG-extension which allow the application to apply some per-connection filters. This filters work at table level and remove records which aren't allowed from a select result-set. Example: CREATE CONNECTION DATA FILTER my_filter CHECKING