Search Postgresql Archives

Re: float to int

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Charles.Hou ha scritto:
> how can i get the int value using the sql language? like this,
> 
> "select cost from my_money_table " , the data type of cost is float.
> 
take a look at
http://www.postgresql.org/docs/8.2/static/sql-expressions.html
CAST ( expression AS type )
expression::type

Edoardo


-- 
Jabber: edoardopa@xxxxxxxxxxxxxxx
tel: 075 9142766

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
       subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your
       message can get through to the mailing list cleanly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux