Hi all,
Does anyone known fi it's possible to make a concatenation of varchar
and float.
I try the request bellow and I don't known how to correct.
seed=> select ((('"' || station) || ('" "' || begining)) || ('" "' ||
ending)) || ('" "' || latitude) from station;
ERROR: There is more than one possible operator '||' for types
'unknown' and 'float8' You will have to retype this query using an explicit cast
seed=> select ((('"' || station) || ('" "' || begining)) || ('" "' ||
ending)) || ('" "'::text || latitude) from station;
ERROR: There is more than one possible operator '||' for types 'text'
and 'float8' You will have to retype this query using an explicit cast
seed=> select ((('"' || station) || ('" "' || begining)) || ('" "' ||
ending)) || ('" "'::text || latitude::float8) from station;
ERROR: There is more than one possible operator '||' for types 'text'
and 'float8' You will have to retype this query using an explicit cast
seed=> \d station
Table = station
+----------------------------------+----------------------------------+-------+
| Field | Type |
Length|
+----------------------------------+----------------------------------+-------+
| network | varchar() not null
| 2 |
| station | varchar() not null
| 5 |
| begining | datetime not null
| 8 |
| ending | datetime
| 8 |
| modified | datetime
| 8 |
| latitude | float8
| 8 |
| lat_prec | int4
| 4 |
| longitude | float8
| 8 |
| long_prec | int4
| 4 |
| coord_type | int4
| 4 |
| coord_map | varchar()
| 100 |
| elevation | float8
| 8 |
I work with postgres 6.4.2
--
Basier Eric e-mail : basier@ipgp.jussieu.fr
http://geoscope.ipgp.jussieu.fr
IPGP Observatoires Sismologie-Volcanologie
4,Place Jussieu 75005 Paris Tour 24-14 4eme Etage Tel 01 44 27 38 96