Oracle中的Split函数
摘要:首先需要定义 2 个类型 1. Row 类型 CREATE OR REPLACE TYPE ty_row_str_split as object (strValue VARCHAR2 (4000)) 2. Table 类型 CREATE OR REPLACE TYPE ty_tbl_str_spli
阅读全文
posted @
2022-04-01 13:50
江湖小虾米L
阅读(3222)
推荐(0)
oracle 取年月日
摘要:1、Oracle 用extract() 函数获取当前年、月、日 select extract(year from sysdate) from dual ;--当前年 select extract(month from sysdate) from dual ;--当前月 select extract(
阅读全文
posted @
2021-10-18 11:44
江湖小虾米L
阅读(12040)
推荐(0)
oracle 查询重复字段
摘要:操作的表名:insurance.tj_vs_price 操作步骤 一、重复记录根据单个字段来判断 1、首先,查找表中多余的重复记录,重复记录是根据单个字段(item_code )来判断 select * from insurance.tj_vs_price where item_code in(se
阅读全文
posted @
2020-09-23 13:30
江湖小虾米L
阅读(343)
推荐(0)
oracle 查询小数点后三位不为‘0’的数据
摘要:select * from dual where trunc(costs,3)!=trunc(costs,2);
阅读全文
posted @
2020-09-09 16:18
江湖小虾米L
阅读(865)
推荐(0)
Oracle 通过出生日期计算年龄
摘要:方法一: SELECT TRUNC(months_between(sysdate, birth)/12) AS age from dual; 方法二: select TRUNC((to_char(sysdate, 'yyyyMMdd') - to_char(birth, 'yyyyMMdd')) /
阅读全文
posted @
2020-06-23 12:01
江湖小虾米L
阅读(1249)
推荐(0)