to_char() //      日期或数字转换为字符串

  1. select sysdate,to_char(sysdate,’yyyy-mm-dd hh24:mi:ss’) from dual   
  2. select sysdate,to_char(sysdate,’yyyy-mm-dd hh:mi:ss’) from dual   
  3. select sysdate,to_char(sysdate,’yyyy-ddd hh:mi:ss’) from dual   
  4. select sysdate,to_char(sysdate,’yyyy-mm iw-d hh:mi:ss’) from dual

to_date() //      字符串转换为日期类型 

to_char(number,'格式')

to_char(salary,'$99.999.99');

to_char处理日期

to_char(date,'格式')

to_date

使用 to_date 将字符转换为 日期  

 

posted on 2015-06-11 17:12  风流书生  阅读(178)  评论(0编辑  收藏  举报