* 날짜 format 모델의 요소
| 요소 | 설명 |
| - | Punctuation and quoted text is reproduced in the result |
| / | |
| , | |
| ‘ | |
| : | |
| . | |
| “test" | |
| AD | AD indicator with or without periods |
| A.D. | |
| AM | Meridian indicator with or without periods |
| A.M. | |
| BC | BC indicator with or without periods |
| B.C. | |
| D | Day of weeks(1-7) |
| DAY | Name of day, padded with blanks to length of 9 characters |
| DD | Day of month(1-31) |
| DDD | Day of year(1-365) |
| DY | Abbreviated name of day |
| HH | Hour of day(0-23) |
| HH12 | |
| MI | Minute(0-59) |
| MM | Month(01-12; JAN=01) |
| MONTH | Name of month, padded with blanks to length of 9 charaters |
| MON | Abbreviated name of month |
| RM | Roman numeral month(I-XII; JAN=I) |
| Q | Quarter of year(1,2,3,4; JAN-MAR=1) |
| RR | Last 2 digits of year; for year in other countries |
| WW(몇번째 주) | Week of year(1-53) wher week 1 starts in the first day of the |
| year and continues to the seventh day of the tear | |
| W(그달의 몇 번째 주) | Week of month(1-5) wher week 1 starts in the first day of the |
| month and ends on the seventh | |
| PM | Meridian indicator with and without periods |
| P.M. | |
| SS | Second(0_59) |
| SSSS | Seconds past midnight(0-86399) |
| Y | Year with comma in this position |
| YYY | |
| YEAR | Year, spelled out; "S" prefixes BC date with "-" |
| SYEAR | |
| YYYY | 4-digit year; "S" prefixes BC data with "-" |
| SYYYY | |
| YYY | Last 3, 2, or 1 digit(s) of year |
| YY | |
| Y |
* RR format의 설명
현재 년도와 명시한 년도의 끝 두자리의 차이가 50 이상 또는 50 이하에 따라 달라짐
RR 날짜 형식
| Current Year | Specified Date | RR format | YY format |
| 1995 | 27-OCT-95 | 1995 | 1995 |
| 1995 | 27-OCT-17 | 2017 | 1917 |
| 2001 | 27-OCT-17 | 2017 | 2017 |
| 2001 | 27-OCT-95 | 1995 | 2095 |
| 명시된 두자리 년도 | |||
| 0 - 49 | 50 - 99 | ||
| 현재년도의 두자리 값 |
0-49 | 되돌려 받는 날짜는 현재의 세기를 나타냄 | |
| 50-99 | 되돌려 받는 날짜는 현재 세기 이후의 나타냄 | ||
'SQL' 카테고리의 다른 글
| 특정 table name 으로 datafile 찾는 쿼리 (0) | 2009/03/09 |
|---|---|
| 날짜 format 모델의 요소 (0) | 2008/10/29 |
| insert 문에서 & 기호 처리 (0) | 2008/10/25 |
| 명시적 데이터 타입 변환 함수 (0) | 2008/10/02 |
| 날짜 함수 (0) | 2008/10/02 |
| 숫자 함수 (0) | 2008/10/02 |

댓글을 달아 주세요