| From: | Donald Jackson <jackson(at)cvrc-taco(dot)mgh(dot)harvard(dot)edu> | 
|---|---|
| To: | pgsql-bugs(at)postgresql(dot)org | 
| Subject: | bug? Coercing float8 to text sticks number in the middle of a date | 
| Date: | 1999-06-02 23:08:47 | 
| Message-ID: | l0311070db37b67d19062@[132.183.120.67] | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-bugs | 
The function:
CREATE FUNCTION zfin_comments(text) RETURNS text AS
'select lod::text || analysis_type::text
AS comments FROM markers WHERE marker_id = $1;'
LANGUAGE 'SQL';
The output:
ssr_db=> select marker_id, lod, analysis_type, zfin_comments(marker_id)
from markers;
marker_id|  lod|analysis_type|zfin_comments
---------+-----+-------------+---------------------------------------
Z8551    |19.27|final        |Fri Dec 31 19:00:19.27 1999 ESTfinal
Z8554    |13.72|final        |Fri Dec 31 19:00:13.72 1999 ESTfinal
Z8563    |18.96|final        |Fri Dec 31 19:00:18.96 1999 ESTfinal
Z8574    |18.96|final        |Fri Dec 31 19:00:18.96 1999 ESTfinal
Z8602    |20.77|final        |Fri Dec 31 19:00:20.77 1999 ESTfinal
Z8604    |17.79|final        |Fri Dec 31 19:00:17.79 1999 ESTfinal
Z8613    |17.16|final        |Fri Dec 31 19:00:17.16 1999 ESTfinal
...
Apparently, when I try to force the float8 value into text
it ends up as seconds in a datetime?  I looked for a function to convert
float to text, but found none...
thanks!
Don Jackson
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Mark Wright | 1999-06-07 16:51:29 | Bug found in beta version | 
| Previous Message | C. Arthur Venable III | 1999-06-02 15:18:13 | 10% off custom web design |