From: | strk <strk(at)keybit(dot)net> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>, Paul Ramsey <pramsey(at)refractions(dot)net>, Mark Cave-Ayland <m(dot)cave-ayland(at)webbased(dot)co(dot)uk>, dblasby(at)refractions(dot)net, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: PostGIS Integration |
Date: | 2004-02-04 17:35:11 |
Message-ID: | 20040204183511.A87894@freek.keybit.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
tgl wrote:
> Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au> writes:
> >> Those two cases are not hard, because in those scenarios the parser
> >> knows it is expecting a type specification. The real problem is this
> >> syntax for typed literals:
> >> typename 'string'
>
> > Just disallow that particular case for custom types :P
>
> Well, maybe we could --- comments? Tom Lockhart went to some lengths to
> support that, but now that he's gafiated we could perhaps rethink it.
> AFAICS the SQL spec only requires this syntax for certain built-in types.
> Tom wanted to generalize that to all datatypes that Postgres supports,
> and that seems like a reasonable goal ... but if it prevents getting to
> other reasonable goals then we ought to think twice.
If it's not for SQL conformance
I don't think we really need to generalize that.
As far as there are other means to gain the same result...
'string'::type(parameter) can be the "general" postgres version.
while varchar(2) 'string' can be the standard SQL version (not general).
--strk;
>
> > Will this work: 'string'::typename
>
> Yes, since the :: cues the parser to expect a typename next.
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend
From | Date | Subject | |
---|---|---|---|
Next Message | Hans-Jürgen Schönig | 2004-02-04 17:47:43 | Re: Recursive queries? |
Previous Message | Hannu Krosing | 2004-02-04 16:42:26 | Re: Recursive queries? |