Re: create function atof? - Mailing list pgsql-sql

From Yasir Malik
Subject Re: create function atof?
Date
Msg-id Pine.NEB.4.58.0406052215060.22758@pink-elephant.cs.stevens-tech.edu
Whole thread Raw
In response to create function atof?  (Mark Tabash <mark.tabash@novacolor.ca>)
List pgsql-sql
> Is it possible to create a database function that mimics the C function atof?
> I'm guessing it should look something like this:

You can do this to convert a string to a float:
select '3.14'::float + 1;
?column?
----------    4.14
(1 row)

Is that what you want?
Yasir


pgsql-sql by date:

Previous
From: Tom Lane
Date:
Subject: Re: ANSI SQL-99 SYNTAX and "WITH"
Next
From: Harald Fuchs
Date:
Subject: Re: postgresql multiple insert slow