# YYYY-MM-DDselect * from (select adddate('1970-01-01',t4.i*10000 + t3.i*1000 + t2.i*100 + t1.i*10 + t0.i) selected_date from (select 0 i union select 1 union select 2 union select 3 union select 4 union select 5 union select 6 union select 7 union select 8 union select 9) t0, (select 0 i union select 1 union select 2 union select 3 union select 4 union select 5 union select 6 union select 7 ..
WITH RECURSIVE CTE AS ( SELECT DEPT_ID, DEPT_NAME, UP_DEPT_ID, DEPT_LOC, DEPT_SORT_ORDR, DEPT_STATUS, DEPT_DEPTH, TOP_DEPT_YN, 1 AS LEVEL FROM ORG_DEPARTMENT UNION ALL SELECT A.DEPT_ID, A.DEPT_NAME, A.UP_DEPT_ID, A.DEPT_LOC, A.DEPT_SORT_ORDR, A.DEPT_STATUS, A.DEPT_DEPTH, A.TOP_DEPT_YN, 1 + B.LEVEL AS LEVEL FROM ORG_DEPARTMENT A INNER JOIN CTE B ON A.UP_DEPT_ID = B.DEPT_ID ) SELECT DISTINCT FUNC_..
##########팀단위########## SELECT (SELECT NAME6 FROM APPLEJARA_PERSON BBBB WHERE NAME5=이름) AS "그룹", (SELECT NAME2 FROM TEST.APPLEJARA_PERSON_DEPT ZZ WHERE NAME3=부서) AS "본부", 부서 AS "팀", (SELECT NAME1 FROM TEST.APPLEJARA_PERSON_DEPT ZZ WHERE NAME3=부서) AS "순서", COUNT(부서) AS "인원", ROUND(AVG(초단위재직),0) "AVG(초단위)", CONCAT(AVG(초단위재직) DIV 86400,'.',DATE_FORMAT(SEC_TO_TIME(AVG(초단위재직) % 86400), '%H'),':',DATE..
SELECT NAME2 AS "부서", NAME4 AS "이름", NAME5 AS "직위", (SELECT NAME1 FROM TEST.PERSON ZZ WHERE NAME5=XX.NAME4) AS "순서", SUM_HH, SUM_MM, SUM_HH*60 AS SUM_HH_60, SUM_MM AS SUM_MM_60, SUM_HH*60 + SUM_MM AS SUM_FINAL, (SUM_HH*60 + SUM_MM)/60 AS SUM_F_HH, ((SUM_HH*60 + SUM_MM)/60)/24 AS SUM_F_DAY FROM ( SELECT NAME2, # "부서" NAME4, # "이름" NAME5, # "직위" NAME25, LPAD(NAME25,7,'00h '), SUBSTR(LPAD(NAME25,7,..
#DB데이터 SELECT NAME3,NAME10,NAME11,NAME12,NAME13 FROM CHECK_VACATION_V2 WHERE NAME13 NOT REGEXP '반차|외근' ORDER BY NAME3 ASC #DB조회결과 SELECT t.NAME3 ,c.Numdate ,t.NAME12 ,t.NAME13 FROM CHECK_VACATION_V2 t JOIN view_calendar c ON c.Numdate BETWEEN DATE_FORMAT(t.NAME10, '%Y-%m-%d') AND DATE_FORMAT(t.NAME11, '%Y-%m-%d') WHERE NAME13 NOT REGEXP '반차|외근' ORDER BY NAME3,c.Numdate ASC ======================..
SELECT ym, MIN(CASE dw WHEN 1 THEN LPAD(d,2,'0') END) Sun, MIN(CASE dw WHEN 2 THEN LPAD(d,2,'0') END) Mon, MIN(CASE dw WHEN 3 THEN LPAD(d,2,'0') END) Tue, MIN(CASE dw WHEN 4 THEN LPAD(d,2,'0') END) Wed, MIN(CASE dw WHEN 5 THEN LPAD(d,2,'0') END) Thu, MIN(CASE dw WHEN 6 THEN LPAD(d,2,'0') END) Fri, MIN(CASE dw WHEN 7 THEN LPAD(d,2,'0') END) Sat FROM (SELECT date_format(dt, '%Y%m') ym, Week(dt) w,..
CREATE TABLE `tb_result_117` ( `STAND_DATE` varchar(8) NOT NULL COMMENT '작업일자', `ITEM_CD` char(12) NOT NULL COMMENT '배치작업의 코드', `SUB_SECTION` varchar(32) NOT NULL COMMENT '배치작업의 코드 하부 작업(하부분류또는 파일명)', `START_TIME` varchar(6) NOT NULL COMMENT '시작시간', `END_TIME` varchar(6) DEFAULT NULL COMMENT '마감시간', `RESULT_MESSAGE` varchar(512) DEFAULT NULL COMMENT '처리결과 메시지', `TOTAL_COUNT` int(11) DEFAULT NULL..
### DB셋팅 / 2016.11.14 # Set the SQL mode to strict sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION" # The maximum amount of concurrent sessions the MySQL server will # allow. One of these connections will be reserved for a user with # SUPER privileges to allow the administrator to login even if the # connection limit has been reached. max_connections=1000 # Query cache i..
- Total
- Today
- Yesterday
- Toad
- tomcat
- server
- 자동차
- select
- IP
- Windows
- mssql
- Oracle
- table
- DATABASE
- Shell
- user
- 파일
- MySQL
- 테이블
- 리눅스
- apache
- 윈도우
- sql
- 백업
- delete
- java
- 설정
- 서버
- Linux
- 오라클
- eclipse
- DB
- 데이터
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |