首页 > 编程学习 > Oracle SYSDATE
20128 月20

Oracle SYSDATE

 select to_char(sysdate,'YYYY/MM/DD') FROM DUAL;             -- 2007/09/20            
 select to_char(sysdate,'YYYY') FROM DUAL;                   -- 2007                  
 select to_char(sysdate,'YYY') FROM DUAL;                    -- 007                   
 select to_char(sysdate,'YY') FROM DUAL;                     -- 07                    
 select to_char(sysdate,'MM') FROM DUAL;                     -- 09                    
 select to_char(sysdate,'DD') FROM DUAL;                     -- 20                    
 select to_char(sysdate,'D') FROM DUAL;                      -- 5                     
 select to_char(sysdate,'DDD') FROM DUAL;                    -- 263                   
 select to_char(sysdate,'WW') FROM DUAL;                     -- 38                    
 select to_char(sysdate,'W') FROM DUAL;                      -- 3                     
 select to_char(sysdate,'YYYY/MM/DD HH24:MI:SS') FROM DUAL;  -- 2007/09/20 15:24:13   
 select to_char(sysdate,'YYYY/MM/DD HH:MI:SS') FROM DUAL;    -- 2007/09/20 03:25:23   
 select to_char(sysdate,'J') FROM DUAL;                      -- 2454364               
 select to_char(sysdate,'RR/MM/DD') FROM DUAL;               -- 07/09/20

本文地址:https://wizzer.cn/archives/2296 , 转载请保留.

本文目前尚无任何评论.

发表评论