Re: the '::' cast doesn't work in the FROM clause
От | Tom Lane |
---|---|
Тема | Re: the '::' cast doesn't work in the FROM clause |
Дата | |
Msg-id | 2614.1314636336@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: the '::' cast doesn't work in the FROM clause (Alexey Klyukin <alexk@commandprompt.com>) |
Список | pgsql-bugs |
Alexey Klyukin <alexk@commandprompt.com> writes: > On Aug 29, 2011, at 5:47 PM, Tom Lane wrote: >> There is a dump/reload bug though :-( ... if you were to do >> >> create view vv as select val from CAST(random() as integer) as val; >> >> you will find that the system prints it out with the :: syntax, >> which won't work. > Would it be acceptable/sufficient to output CAST(...) instead of '::' for all casts in pg_dump to fix this problem, assumingthat CAST can be used anywhere where '::' is accepted? I'm not really excited about that; CAST is more verbose and not particularly more readable (at least IMO). What I was wondering about was altering the internal representation to remember which format had been used, and reverse-listing in that same format. That would both fix this issue, and please users who have a stylistic preference for one or the other format. regards, tom lane
В списке pgsql-bugs по дате отправления: