Skip site navigation (1) Skip section navigation (2)

Re: BUG #4402: Column expansion: date comes wthout a cast

From: Euler Taveira de Oliveira <euler(at)timbira(dot)com>
To: Joachim Unger <jo(dot)unger(at)arcor(dot)de>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #4402: Column expansion: date comes wthout a cast
Date: 2008-09-06 01:56:24
Message-ID: 48C1E348.3030109@timbira.com (view raw or flat)
Thread:
Lists: pgsql-bugs
Joachim Unger escreveu:
> The column expansion lists date types without a date cast.
> 
And all of the text types too.

> Here is an example where I'm using NEW inside a trigger:
> [...]
> ins_sql := 'INSERT INTO ' ||   quote_ident(new_child_table) || '('
> ||col_names(new_child_table) || ') VALUES ' || NEW;
> RAISE NOTICE 'INSERT: %',ins_sql;
> EXECUTE ins_sql;
> [...]
> 
Why aren't you expanding it yourself? Currently, PostgreSQL doesn't have
a function that does the quoting-if-needed automagically.


-- 
  Euler Taveira de Oliveira
  http://www.timbira.com/

In response to

pgsql-bugs by date

Next:From: Ross TooleDate: 2008-09-06 06:20:06
Subject: BUG #4404: Installation Appears to work service fails
Previous:From: Bruce MomjianDate: 2008-09-06 00:42:44
Subject: Re: BUG #4377: casting result of timeofday() to timestamp fails in some timezones

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group