Re: [HACKERS] [BUG] views and functions on relations

2001-04-17 Thread Tom Lane
Alex Pilosov <[EMAIL PROTECTED]> writes: > users=# \d tv2 > ERROR: cache lookup of attribute 0 in relation 21747 failed Confirmed here. Too tired to chase it further tonight, though. > HOWEVER, 'select * from tv2' succeeds (sometimes). Sometimes it fails with > the same error (cache lookup fai

Re: [HACKERS] Re: No printable 7.1 docs?

2001-04-17 Thread Tom Lane
Thomas Lockhart <[EMAIL PROTECTED]> writes: > There is a difference between using techniques which markup content > (DocBook, XML, etc) as opposed to those which markup appearence (latex). Perhaps I'm stuck in the eighties when I did my thesis in LaTeX, but I was of the impression that what's con

Re: [HACKERS] plpgsql problem

2001-04-17 Thread Stephan Szabo
My guess is that since userid and userID differ only in case, it's probably not actually using the aliased version and instead is using only the column one. The execute is different since you're effectively putting the *value* of userID into the query as opposed to the word. I'd suggest renaim

Re: [HACKERS] Re: No printable 7.1 docs?

2001-04-17 Thread Thomas Lockhart
> 5) We have been working for translating docs into Japanese using >EUC_JP encoding. Converting to HTML is no problem, but we cannot >get correct results for sgml-> RTF conversion at all. The >translated docs are just not be able to read, showing random >characters. It seems that o

Re: [HACKERS] timeout on lock feature

2001-04-17 Thread Theo Kramer
> Timeouts are a system-level mechanism that to be useful must refer to > system-level events that are far above anything that PG knows about. > The only way PG could apply reasonable timeouts would be for the > application to dictate them, but the application can better implement > them itse

Re: [HACKERS] plpgsql problem

2001-04-17 Thread Tom Lane
Lehel Gyuro <[EMAIL PROTECTED]> writes: > -- the same applies to inline queries too. if issued with execute > -- everything is fine, but if the query has more than one arguments > -- the compiler dismisses all, except the last one This is more than slightly hard to believe. There are thousands o

[HACKERS] [BUG] views and functions on relations

2001-04-17 Thread Alex Pilosov
In latest 7.1 (checked out 2 days ago from CVS), I see following behaviour: create table foo(x int4); create function xx(foo) returns int4 as ' return 0;' language 'plpgsql'; create view tv2 as select xx(foo) from foo; users=# \d tv2 ERROR: cache lookup of attribute 0 in relation 21747 failed

Re: [HACKERS] Re: [BUGS] three VERY minor things with 7.1 final

2001-04-17 Thread The Hermit Hacker
On Tue, 17 Apr 2001, Tom Lane wrote: > David George <[EMAIL PROTECTED]> writes: > > I just built the postgresql 7.1 final and the configure script is still > > checking for sfio. Not a major big deal, but I need to remove the sfio > > check from configure.in, run autoconf, and then configure to

Re: [HACKERS] Re: No printable 7.1 docs?

2001-04-17 Thread Tatsuo Ishii
> Hmm. Actually, afaik we were the first large open source project to > successfully use the jade toolset for docs. Others have used our project > as an example to help get them going, since as you have already found > out getting the tool chain completely set up is not trivial. > > There are at

Re: [HACKERS] Re: timeout on lock feature

2001-04-17 Thread Ian Lance Taylor
"Henryk Szal" <[EMAIL PROTECTED]> writes: > YES, I DO! My transaction can't wait. > If parser on planner is blocked, then i want to abort my transaction. What are your actual timing constraints? Is the constraint ``no database table access may take longer than 10 seconds?'' Or is it ``no datab

Re: [HACKERS] Re: timeout on lock feature

2001-04-17 Thread Tom Lane
"Henryk Szal" <[EMAIL PROTECTED]> writes: > YES, this feature should affect ALL locks. > 'Timeout on lock' parameter says to server "I CAN'T WAIT WITH THIS > TRANSACTION TOO LONG BECAUSE OF (ANY) LOCK", It still seems to me that what such an application wants is not a lock timeout at all, but an

[HACKERS] doubts

2001-04-17 Thread Francisco Alvarez
Greetings which it is the driver JDBC that allows me the connection of Matlab and PostgreSQL and where I look for it there am I install. He/she would have some simple example of the code that I should add Matlab. Thank you. _

[HACKERS] Re: Large Object problems (was Re: JDBC int8 hack)

2001-04-17 Thread Kyle VanderBeek
On Tue, Apr 17, 2001 at 09:11:54AM -0400, Peter T Mount wrote: > Erm, int8 isn't long, but an array of 8 int's (unless it's changed). http://postgresql.readysetnet.com/users-lounge/docs/7.0/user/datatype.htm#AEN942 It is very much an 8-byte integer, the correlary to Java's Long/long. -- Kyle.

[HACKERS] Re: timeout on lock feature

2001-04-17 Thread Henryk Szal
Tom Lane wrote in message <[EMAIL PROTECTED]>... >Bruce Momjian <[EMAIL PROTECTED]> writes: >> I was thinking SET because UPDATE does an auto-lock. > >Not to mention a ton of implicit locks acquired on various system tables >during parsing/planning. You really want auto timeout on all of those?

[HACKERS] Handling error messages

2001-04-17 Thread Víctor R. Ruiz
Hi: One of the most obvious things that should do a database is to check for data integrity and values, but programming with PHP and other languages I see that we duplicate this task: one on the client side (with javascript), sometimes on server side (on PHP) and finally on the database serv

[HACKERS] Re: timeout on lock feature

2001-04-17 Thread Henryk Szal
YES, this feature should affect ALL locks. 'Timeout on lock' parameter says to server "I CAN'T WAIT WITH THIS TRANSACTION TOO LONG BECAUSE OF (ANY) LOCK", so if my process is in conflict with another (system or user) process, then i want to abort my transaction. Somebody can set timeout to bigger

[HACKERS] plpgsql problem

2001-04-17 Thread Lehel Gyuro
CREATE FUNCTION userHasAll (int4,int4) RETURNS boolean AS ' DECLARE row RECORD; kirakorow kirakok%ROWTYPE; userID ALIAS FOR $1; kirakoID ALIAS FOR $2; megvan int4:=0; kepdarabok INTEGER:=0; query text; BEGIN SELECT * INTO kirakorow FROM kirakok WHERE kirako_id=kirakoID; -- this wor

[HACKERS] Re: [BUGS] three VERY minor things with 7.1 final

2001-04-17 Thread Tom Lane
David George <[EMAIL PROTECTED]> writes: > I just built the postgresql 7.1 final and the configure script is still > checking for sfio. Not a major big deal, but I need to remove the sfio > check from configure.in, run autoconf, and then configure to fix it. If > you remember sfio on Sparc Solar

Re: [HACKERS] timeout on lock feature

2001-04-17 Thread Nathan Myers
On Tue, Apr 17, 2001 at 12:56:11PM -0400, Tom Lane wrote: > In short, I think lock timeout is a solution searching in vain for a > problem. If we implement it, we are just encouraging bad application > design. I agree with Tom completely here. In any real-world application the database is the k

Re: [HACKERS] Foolish question about <<<< SELECT INTO rec xxx, xxxx, xxx, xxx WHERE YYYYYY ilike %$2 >>>>

2001-04-17 Thread Tom Lane
I think you haven't counted your quotes correctly. quote_literal() would probably help you build a valid ILIKE pattern with less pain. regards, tom lane ---(end of broadcast)--- TIP 3: if posting/reading through Usenet, ple

[HACKERS] Foolish question about <<<< SELECT INTO rec xxx, xxxx, xxx, xxx WHERE YYYYYY ilike %$2 >>>>

2001-04-17 Thread Jean-Michel POURE
Hello Dave & friends, I am working on the PgAdmin query loader project writing as much possible code server-side in PL/pgSQL. For the purpose of function 'compilation' (let's call it like that), I create two temporary tables: compiler_function which holds the list of PL/PgSQL functions to com

Re: [HACKERS] 7.1 on 7.1

2001-04-17 Thread Trond Eivind Glomsrød
[EMAIL PROTECTED] (Trond Eivind Glomsrød) writes: > PostgreSQL 7.1 on Red Hat Linux 7.1[1]: All 76 tests passed. > > I'll submit it to the website soonish. > > [1] Available this morning, >http://www.redhat.com/about/presscenter/2001/press_sevenone.html I've not been able to submit it - the

Re: [HACKERS] Authentication with PGSQL

2001-04-17 Thread Tom Lane
Jean-Eric Cuendet <[EMAIL PROTECTED]> writes: > With PGSQL you can authenticate with KRB5 or a proprietary /etc/passwd > Is it planned to use other methods of authenticating? > LDAP? > PAM? > SASL? I seem to recall some discussion of PAM support. Want to do the work? reg

SV: [HACKERS] Foreign key checks/referential integrity.

2001-04-17 Thread Jarmo Paavilainen
Hi, ... > key reference). Isn't then the query valid for those tuples which do not > result in a violation of the referential integrity test? Shouldn't those > tuples in a be deleted? The "all or nothing" approach causes this. And _here_ **I think** its correct behaviour. (IMHO user and backend

Re: [HACKERS] Re: [PATCHES] Patch for PostgreSQL 7.0.3 to compile on Tru64 UNIX v5.0A

2001-04-17 Thread Tom Lane
Alessio Bragadini <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> Sounds good; could you check the regress tests too? > *** ./expected/float8-fp-exception.outThu Mar 30 10:46:00 2000 > --- ./results/float8.out Tue Apr 17 20:09:17 2001 > *** > *** 214,220 > SET

RE: AW: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Mikheev, Vadim
> > The timeout will be useful to let the client or user decide > > on an alternate course of action other that killing his > > application (without the need for timers or threads in the > > client program). > > This assumes (without evidence) that the client has a good > idea of what the timeout

Re: [HACKERS] Another news story in need of 'enlightenment'

2001-04-17 Thread Nathan Myers
On Tue, Apr 17, 2001 at 01:31:43PM -0400, Lamar Owen wrote: > This one probably needs the 'iron hand and the velvet paw' touch. The > iron hand to pound some sense into the author, and the velvet paw to > make him like having sense pounded into him. Title of article is 'Open > Source Databases Wo

Re: [HACKERS] Real/effective user

2001-04-17 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes: > Terminology note: In SQL 'real user' == SESSION_USER, 'effective user' == > CURRENT_USER. Not sure about that. I suspect that we actually need three values: 1. "real user" = what you originally authenticated to the postmaster. 2. "session user" =

[HACKERS] Strange behaviour of to_date()

2001-04-17 Thread Mario Weilguni
I noticed a quite strange behaviour of to_char() in 7.0 and 7.1. It treats abbreveated forms of a date completely wrong. Example: -- this one is ok mario=# select to_date('04.01.2001', 'dd.mm.'); to_date 2001-01-04 -- this is completly wrong, but NO error raised mario=# sele

RE: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Mikheev, Vadim
> > Added to TODO: > > * Add SET parameter to timeout if waiting for lock too long > > I repeat my strong objection to any global (ie, affecting all locks) > timeout. Such a "feature" will have unpleasant consequences. But LOCK TABLE T IN ROW EXCLUSIVE MODE WITH TIMEOUT X will not give requ

Re: [HACKERS] Re: No printable 7.1 docs?

2001-04-17 Thread Thomas Lockhart
> It seems to me that all of the other problems you enumerate are simply > bugs in the doc toolchain. We've worked around them rather than tried > to fix them because that was the shortest path to a result, but if Chris > wants to tackle actually fixing them, that would sure be nice. Based on >

[HACKERS] Authentication with PGSQL

2001-04-17 Thread Jean-Eric Cuendet
Hi, With PGSQL you can authenticate with KRB5 or a proprietary /etc/passwd Is it planned to use other methods of authenticating? LDAP? PAM? SASL? I'm in the process of centralizing authentication of users for all our services but it's not possible in the current state of PGSQL. Thanks for any i

Re: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Tom Lane
Michael Ansley <[EMAIL PROTECTED]> writes: > Sorry for my forgetfulness (and a search through geocrawler didn't turn up > anything useful), but what was the problem with something like NOWAIT? > e.g.: SELECT * FROM a FOR UPDATE NOWAIT; > where, if the required lock could not be obtained immediatel

RE: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Michael Ansley
Title: RE: AW: [HACKERS] timeout on lock feature Sorry for my forgetfulness (and a search through geocrawler didn't turn up anything useful), but what was the problem with something like NOWAIT? e.g.: SELECT * FROM a FOR UPDATE NOWAIT; where, if the required lock could not be obtained imme

AW: AW: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Zeugswetter Andreas SB
> > The timeout will be useful to let the client or user decide on an > > alternate course of action other that killing his application (without > > the need for timers or threads in the client program). > > This assumes (without evidence) that the client has a good idea of what > the timeout li

Re: AW: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Tom Lane
Zeugswetter Andreas SB <[EMAIL PROTECTED]> writes: > The timeout will be useful to let the client or user decide on an > alternate course of action other that killing his application (without > the need for timers or threads in the client program). This assumes (without evidence) that the client

Re: [HACKERS] Re: [PATCHES] Patch for PostgreSQL 7.0.3 to compile on Tru64 UNIX v5.0A

2001-04-17 Thread Alessio Bragadini
Tom Lane wrote: > Sounds good; could you check the regress tests too? Mmmmhhh... Failed the int8 test, but seems more a difference in the text of the error message. The others 75 were successful. diff attached -- Alessio F. Bragadini[EMAIL PROTECTED] APL Financial Services

[HACKERS] Modified driver to better handle NULL values...

2001-04-17 Thread Jeroen Habets
Hi, I have just modified the jdbc 7.1rc4 source to let the PreparedStatement handle null values in setXXX methods gracefully... According to JDBC a setXXX method should send a NULL if a null value is supplied (and not raise an exception or other) How can I contribute? Jeroen

Re: [HACKERS] Re: [PATCHES] Patch for PostgreSQL 7.0.3 to compile on Tru64 UNIX v5.0A

2001-04-17 Thread Tom Lane
Alessio Bragadini <[EMAIL PROTECTED]> writes: > Tom Lane wrote: > I can add up my experience of building on Tru64 4.0f (Compaq DS20E) > without problems, using Digital's cc >> >> Would you check whether things still work on your platform if CC becomes >> "cc -std -ieee" rather than just "cc -std"

Re: [HACKERS] Re: No printable 7.1 docs?

2001-04-17 Thread Peter Eisentraut
Tom Lane writes: > It seems to me that all of the other problems you enumerate are simply > bugs in the doc toolchain. We've worked around them rather than tried > to fix them because that was the shortest path to a result, but if Chris > wants to tackle actually fixing them, that would sure be

Re: AW: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Tom Lane
Zeugswetter Andreas SB <[EMAIL PROTECTED]> writes: > The timeout will be useful to let the client or user decide on an > alternate course of action other that killing his application (without > the need for timers or threads in the client program). Okay, let's take a close look at this assumptio

[HACKERS] Another news story in need of 'enlightenment'

2001-04-17 Thread Lamar Owen
This one probably needs the 'iron hand and the velvet paw' touch. The iron hand to pound some sense into the author, and the velvet paw to make him like having sense pounded into him. Title of article is 'Open Source Databases Won't Fly' -- http://www.dqindia.com/content/enterprise/datawatch/1010

[HACKERS] Real/effective user

2001-04-17 Thread Peter Eisentraut
I just read on -general that it is envisoned to have a SET command to temporarily change the effective user id (for superusers only), so that pg_dump generated scripts won't have to use \connect and be forced to run under excessively loose permissons. This isn't hard to do, in fact we probably on

Re: [HACKERS] Re: [PATCHES] Patch for PostgreSQL 7.0.3 to compile on Tru64 UNIX v5.0A

2001-04-17 Thread Alessio Bragadini
Tom Lane wrote: > > I can add up my experience of building on Tru64 4.0f (Compaq DS20E) > > without problems, using Digital's cc > > Would you check whether things still work on your platform if CC becomes > "cc -std -ieee" rather than just "cc -std"? (Best way to check is to > alter src/templa

Re: [HACKERS] Re: [PATCHES] Patch for PostgreSQL 7.0.3 to compile on Tru64 UNIX v5.0A

2001-04-17 Thread Alessio Bragadini
> Mmmmhhh... Failed the int8 test Sorry, float8 -- Alessio F. Bragadini[EMAIL PROTECTED] APL Financial Services http://village.albourne.com Nicosia, Cyprus phone: +357-2-755750 "It is more complicated than you think" -- The Eighth Networking

[HACKERS] row archiving trigger function

2001-04-17 Thread Louis-David Mitterrand
In our DB schema we have defined a class of tables containing important data for which we'd like to keep an audit trail of any change. These tables have the following inheritance structure: +>(real, live table with constraints) _type | +> _archive (

AW: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Zeugswetter Andreas SB
> > Added to TODO: > > * Add SET parameter to timeout if waiting for lock too long > > I repeat my strong objection to any global (ie, affecting all locks) > timeout. Such a "feature" will have unpleasant consequences. Except that other people like myself, see those consequences as a plea

AW: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Zeugswetter Andreas SB
> > Bruce Momjian <[EMAIL PROTECTED]> writes: > > > Added to TODO: > > > * Add SET parameter to timeout if waiting for lock too long > > > > I repeat my strong objection to any global (ie, affecting all locks) > > timeout. Such a "feature" will have unpleasant consequences. > > I envisioned:

Re: [HACKERS] Re: Large Object problems (was Re: JDBC int8 hack)

2001-04-17 Thread Tom Lane
Peter T Mount <[EMAIL PROTECTED]> writes: >> Ah, it just dawned on me what might be happening: Peter, I'm guessing >> that you are thinking of "INT48" or some such, the pseudo-integer array >> type. Kyle is referring to the "int8" 8 byte integer type. > Ah, that would explain it. However int8 (as

Re: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > I envisioned: > SET TIMEOUT TO 10; > UPDATE tab SET col = 3; > RESET TIMEOUT > Can't we get that work work properly? Let the timeout only apply to the > 'tab' table and none of the others. As Henryk has implemented it, it WON'T only

Re: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Added to TODO: > * Add SET parameter to timeout if waiting for lock too long I repeat my strong objection to any global (ie, affecting all locks) timeout. Such a "feature" will have unpleasant consequences. regards, tom l

Re: [HACKERS] Re: No printable 7.1 docs?

2001-04-17 Thread Tom Lane
Thomas Lockhart <[EMAIL PROTECTED]> writes: > 3) Page breaks are not always ideal. Some hand adjustments are desirable > to get a better flow to the docs, especially wrt examples and lists; you > don't want them breaking between pages if you can avoid it, especially > with short examples. This ob

AW: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Zeugswetter Andreas SB
> > I envisioned: > > > SET TIMEOUT TO 10; > > UPDATE tab SET col = 3; > > RESET TIMEOUT > > > Can't we get that work work properly? Let the timeout only > apply to the > > 'tab' table and none of the others. > > As Henryk has implemented it, it WON'T only apply to the 'tab' tabl

Re: [HACKERS] Re: [PATCHES] Patch for PostgreSQL 7.0.3 to compile on Tru64 UNIX v5.0A

2001-04-17 Thread Tom Lane
Alessio Bragadini <[EMAIL PROTECTED]> writes: > Thomas Lockhart wrote: >> We had at least three reports of successful compilation on Tru64 4.0[dg] > I can add up my experience of building on Tru64 4.0f (Compaq DS20E) > without problems, using Digital's cc Would you check whether things still wor

Re: AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Bruce Momjian
Added to TODO: * Add SET parameter to timeout if waiting for lock too long > > > I was thinking SET because UPDATE does an auto-lock. > > Optimal would imho be a SET that gives a maximum amount of time in seconds > the client is willing to wait for any lock. But I

[HACKERS] Re: No printable 7.1 docs?

2001-04-17 Thread Thomas Lockhart
> My feedback at this time is mostly the desire to know a bit better > what prevents the hardcopy docs from being built automatically. I am > currently having some trouble compiling jadetex, so I can't take a > look at the generated PDF yet, but I assume there's something wrong > with it. That s

[HACKERS] Re: Large Object problems (was Re: JDBC int8 hack)

2001-04-17 Thread Thomas Lockhart
> Erm, int8 isn't long, but an array of 8 int's (unless it's changed). int8 is a 64-bit integer. There used to be a type (maybe called int48 ??) which was 8 4-byte integers. afaicr that is now called oidvector (and there is an int2vector also). The name changes for these latter types were fairly

[HACKERS] Re: RedHat/Postgres.pm Error

2001-04-17 Thread Alessio Bragadini
Allan C Huffman wrote: > May I please ask you guys a question about Postgres.pm. What is Postgres.pm? Talking about DBD::Pg or something completely different? -- Alessio F. Bragadini[EMAIL PROTECTED] APL Financial Services http://village.albourne.com Nicosia, Cyprus

[HACKERS] Talk on Open Source vs Proprietry databases

2001-04-17 Thread Theo Kramer
Hi I have been volunteered to give a talk at a Linux conference (http://www.linuxafrica.co.za). The context is the following A Comparative Analysis of Opensource and Proprietry Database Technologies Several options exist for selecting a database on Opensource operating systems such as Linux a

[HACKERS] Re: [PATCHES] Patch for PostgreSQL 7.0.3 to compile on Tru64 UNIX v5.0A

2001-04-17 Thread Alessio Bragadini
Thomas Lockhart wrote: > We had at least three reports of successful compilation on Tru64 4.0[dg] I can add up my experience of building on Tru64 4.0f (Compaq DS20E) without problems, using Digital's cc ./configure --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-maxba

RE: [HACKERS] Foreign key checks/referential integrity.

2001-04-17 Thread Michael Ansley
Title: RE: [HACKERS] Foreign key checks/referential integrity. No, they shouldn't.  If you want to delete only those tuples that aren't referenced in b then you must explicitly say so: delete from a where not exists (select * from b where b.b = a.a); The query that you tried will explicitly

Re: [HACKERS] broken web server?

2001-04-17 Thread Vince Vielhaber
Removed from active rotation and site admin notified. Vince. On Mon, 16 Apr 2001, bpalmer wrote: > I know this isn't really hackers traffic, but... > > one of the servers in www.postgresql.org is > > http://postgresql.bbksys.com/ > > which is giving me 404 errors.. > > I've mailed webmaster@

[HACKERS] Foreign key checks/referential integrity.

2001-04-17 Thread Gavin Sherry
Hi guys, I've just come up with a hypothetical which, in my opinion, points to a flaw in the foreign key implementation in Postgres. All tests were conducted on 7.1beta4 -- not the most up to date, but I have seen no reference to this in the mailing list/todo (ie, in 'foreign' under TODO.detail).

AW: [HACKERS] timeout on lock feature

2001-04-17 Thread Zeugswetter Andreas SB
> I was thinking SET because UPDATE does an auto-lock. Optimal would imho be a SET that gives a maximum amount of time in seconds the client is willing to wait for any lock. But I liked the efficiency of Henryk's code. > > > Bruce Momjian <[EMAIL PROTECTED]> writes: > > > I can imagine some