From: | Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | clark(dot)evans(at)manhattanproject(dot)com (Clark Evans) |
Cc: | hackers(at)postgreSQL(dot)org |
Subject: | Re: [HACKERS] Associative Operators? (Was: Re: [NOVICE] Out of frying pan, into fire) |
Date: | 1999-03-16 22:23:52 |
Message-ID: | 199903162223.RAA20888@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> Seth McQuale pointed out that the follwing does not work:
> SELECT LASTNAME || ',' || FIRSTNAME [AS] NAME FROM FRIENDS;
>
> The solution, was:
> SELECT ( LASTNAME || ',' ) || FIRSTNAME AS NAME FROM FRIENDS;
>
> I looked at pg_operator and didn't see any flag to mark
> an operator as 'associative'. Perhaps if we added a flag
> like this, the re-write system could be modified to handle
> cases like this.
>
> Thoughts?
>
> Clark Evans
>
>
My guess is that we should auto-left-associate functions like || if no
parens are present. It would be a small change to the parser.
--
Bruce Momjian | http://www.op.net/~candle
maillist(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 1999-03-16 22:33:40 | Re: [HACKERS] Re: postmaster dies (was Re: Very disappointing performance) |
Previous Message | secret | 1999-03-16 22:20:49 | Re: [HACKERS] Re: postmaster dies (was Re: Very disappointing performance) |