当前位置:首页 > 数据库 > Oracle

MySQL与Oracle常用函数

Oracle to_char(sysdate,yyyy-MM-dd HH24:mm:ss) // MySQL select date_format(now(),%Y-%m-%d %H:%i:%s)
  • 数字转字符串
//Oracle
to_char(1)

//MySQL
select cast(number as char)  / select cast(123 as char)
select concat(123,‘‘)
  • 字符串转数字
//Oracle
to_number(sort)

//MySQL
cast(sort as signed integer)
  • 2个字符串返回一个非空的 (NULL)
//Oracle
select NVL(expr1,expr2)

//MySQL
select ifnull(expr1,expr2)

 

MySQL与Oracle常用函数

标签:form   concat   har   sysdate   weight   signed   col   orm   char   

本文系统来源:https://www.cnblogs.com/fengxueyi/p/13997588.html


【说明】本文章由站长整理发布,文章内容不代表本站观点,如文中有侵权行为,请与本站客服联系(QQ:254677821)!

相关教程推荐

其他课程推荐