Tony Capobianco wrote:
> Here's my table:
>
> plsql_dw=# \d tmpsv_parent_master
>Table "staging.tmpsv_parent_master"
>
> Why won't this work?
> plsql_dw=# select memberid || addeddate from tmpsv_parent_master limit
> 10;
> ERROR: operator does not exist: numeric || timestamp withou
Here's my table:
plsql_dw=# \d tmpsv_parent_master
Table "staging.tmpsv_parent_master"
Column |Type | Modifiers
+-+---
memberid | numeric |
addeddate | timestamp witho
On 2010-12-08, Tony Capobianco wrote:
> Thanks so much to everyone for your responses. You've been very
> helpful. I'm running PostGres 8.4 and we're migrating our datawarehouse
> from Oracle 10.2. I guess datatype is implicitly cast in oracle under
> these circumstances:
>
> SQL> create table
Thanks so much to everyone for your responses. You've been very
helpful. I'm running PostGres 8.4 and we're migrating our datawarehouse
from Oracle 10.2. I guess datatype is implicitly cast in oracle under
these circumstances:
SQL> create table tony_test as select memberid||addeddate "data" fro
I don't know what Postgres version you're using but check out the doc
related to String Functions and Operators.
Cheers,
Peter
On Tue, Dec 7, 2010 at 4:47 PM, Tony Capobianco
wrote:
> Ok, that worked. Why did I need to cast both as text though?
>
> plsql_dw=# select memberid::text||addeddate
On Tue, Dec 7, 2010 at 1:47 PM, Tony Capobianco
wrote:
> Why did I need to cast both as text though?
http://www.postgresql.org/docs/8.3/interactive/release-8-3.html#AEN87134
--
Regards,
Richard Broersma Jr.
--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your
What does a 'timestamp || numeric' actually look like? It
means the timestamp written out a.k.a text and the same for
numeric. The database does not know that that is what you
wanted without the casts to text.
Cheers,
Ken
On Tue, Dec 07, 2010 at 04:47:46PM -0500, Tony Capobianco wrote:
> Ok, that
Hey Tony,
Because there is no implicit conversion to text.
2010/12/8 Tony Capobianco
> Ok, that worked. Why did I need to cast both as text though?
>
> plsql_dw=# select memberid::text||addeddate::text from
> tmpsv_parent_master limit 5;
> ?column?
> --
>
I think the HINT is what you need to look at.
Cast both columns to text.
On Tue, Dec 7, 2010 at 4:37 PM, Tony Capobianco
wrote:
> Here's my table:
>
>plsql_dw=# \d tmpsv_parent_master
> Table "staging.tmpsv_parent_master"
> Column |Type
Ok, that worked. Why did I need to cast both as text though?
plsql_dw=# select memberid::text||addeddate::text from
tmpsv_parent_master limit 5;
?column?
--
4005941032010-11-16 19:32:17
4005941952010-11-16 19:33:29
4005942842010-11-16 19:34:32
Here's my table:
plsql_dw=# \d tmpsv_parent_master
Table "staging.tmpsv_parent_master"
Column |Type | Modifiers
+-+---
memberid | numeric
11 matches
Mail list logo