Re: error: cast the timestam expression

From: Michael Glaesemann <grzm(at)myrealbox(dot)com>
To: friendVU admin <maillist(at)friendvu(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: error: cast the timestam expression
Date: 2005-01-28 15:04:30
Message-ID: E948899A-713D-11D9-8469-000A95C88220@myrealbox.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


On Jan 28, 2005, at 23:55, friendVU admin wrote:

> When I execute this:
> "insert into comments
> (
> date_posted
> )
> (select date_published
> from xyz
> )"
>
> I get :
> "ERROR: column "date_posted" is of type timestamp without time zone
> but expression is of type text
> HINT: You will need to rewrite or cast the expression."
>
> Both dates are of type timesamp!

Could you post the output to \d xyz and \d comments from psql?

Michael Glaesemann
grzm myrealbox com

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Franco Bruno Borghesi 2005-01-28 15:46:50 Re: Calendar Function
Previous Message Tom Lane 2005-01-28 15:04:12 Re: error: cast the timestam expression