인, 내부 링크 와 빈 값
SQL> select * from emp;
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
---------- ---------- ---------- ---------- -------------- ---------- ---------- ----------
7369 SMITH CLERK 7902 17-12 -80 800 20
7499 ALLEN SALESMAN 7698 20-2 -81 1600 300 30
7521 WARD SALESMAN 7698 22-2 -81 1250 500 30
7566 JONES MANAGER 7839 02-4 -81 2975 20
7654 MARTIN SALESMAN 7698 28-9 -81 1250 1400 30
7698 BLAKE MANAGER 7839 01-5 -81 2850 30
7782 CLARK MANAGER 7839 09-6 -81 2450 10
7788 SCOTT ANALYST 7566 09-12 -82 3000 20
7839 KING PRESIDENT 17-11 -81 5000 10
7844 TURNER SALESMAN 7698 08-9 -81 1500 0 30
7876 ADAMS CLERK 7788 12-1 -83 1100 20
7900 JAMES CLERK 7698 03-12 -81 950 30
7902 FORD ANALYST 7566 03-12 -81 3000 20
7934 MILLER CLERK 7782 23-1 -82 1300 10
14 。
SQL> select * from emp2 order by 1;
ENAME JOB SAL
---------- ---------- ----------
ADAMS CLERK 1100
ADAMS CLERK 1100
JAMES CLERK 950
JAMES CLERK 950
MILLER CLERK 1300
MILLER CLERK 1300
SMITH CLERK 800
SMITH CLERK 800
8 。
SQL> SELECT empno, ename, job, sal, deptno
2 FROM emp
3 WHERE (ename, job, sal) IN (SELECT ename, job, sal FROM emp2);
EMPNO ENAME JOB SAL DEPTNO
---------- ---------- ---------- ---------- ----------
7369 SMITH CLERK 800 20
7876 ADAMS CLERK 1100 20
7900 JAMES CLERK 950 30
7934 MILLER CLERK 1300 10
SQL> SELECT a.empno, a.ename, a.job, a.sal, a.deptno
2 FROM emp a
3 INNER JOIN emp2 b ON (b.ename = a.ename AND b.job = a.job AND
4 b.sal = a.sal);
EMPNO ENAME JOB SAL DEPTNO
---------- ---------- ---------- ---------- ----------
7369 SMITH CLERK 800 20
7369 SMITH CLERK 800 20
7876 ADAMS CLERK 1100 20
7876 ADAMS CLERK 1100 20
7900 JAMES CLERK 950 30
7900 JAMES CLERK 950 30
7934 MILLER CLERK 1300 10
7934 MILLER CLERK 1300 10
8 。
EMP2 , ,
SQL> SELECT distinct a.empno, a.ename, a.job, a.sal, a.deptno
2 FROM emp a
3 INNER JOIN emp2 b ON (b.ename = a.ename AND b.job = a.job AND
4 b.sal = a.sal);
EMPNO ENAME JOB SAL DEPTNO
---------- ---------- ---------- ---------- ----------
7900 JAMES CLERK 950 30
7876 ADAMS CLERK 1100 20
7369 SMITH CLERK 800 20
7934 MILLER CLERK 1300 10
IN ?
SQL> select * from emp2 order by 6 nulls last;
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
---------- ---------- ---------- ---------- -------------- ---------- ---------- ----------
7876 ADAMS CLERK 7788 12-1 -83 1100 20
7521 WARD SALESMAN 7698 22-2 -81 1250 500 30
7654 MARTIN SALESMAN 7698 28-9 -81 1250 1400 30
7934 MILLER CLERK 7782 23-1 -82 1300 10
7844 TURNER SALESMAN 7698 08-9 -81 1500 0 30
7499 ALLEN SALESMAN 7698 20-2 -81 1600 300 30
7782 CLARK MANAGER 7839 09-6 -81 2450 10
7698 BLAKE MANAGER 7839 01-5 -81 2850 30
7566 JONES MANAGER 7839 02-4 -81 2975 20
7788 SCOTT ANALYST 7566 09-12 -82 3000 20
7902 FORD ANALYST 7566 03-12 -81 3000 20
7839 KING PRESIDENT 17-11 -81 5000 10
7369 SMITH CLERK 7902 17-12 -80 20
7900 JAMES CLERK 7698 03-12 -81 30
14 。
SQL> select * from emp3 order by 3 nulls last;
ENAME JOB SAL
---------- ---------- ----------
ADAMS CLERK 1100
MILLER CLERK 1300
JAMES CLERK
SMITH CLERK
SQL> SELECT empno, ename, job, sal, deptno
2 FROM emp2
3 WHERE (ename, job, sal) IN (SELECT ename, job, sal FROM emp3);
EMPNO ENAME JOB SAL DEPTNO
---------- ---------- ---------- ---------- ----------
7876 ADAMS CLERK 1100 20
7934 MILLER CLERK 1300 10
SMITH JAMES 2 , :
SQL> SELECT empno, ename, job, sal, deptno
2 FROM emp2
3 WHERE (ename || job || sal) IN (SELECT ename || job || sal FROM emp3);
EMPNO ENAME JOB SAL DEPTNO
---------- ---------- ---------- ---------- ----------
7369 SMITH CLERK 20
7876 ADAMS CLERK 1100 20
7900 JAMES CLERK 30
7934 MILLER CLERK 1300 10
이 내용에 흥미가 있습니까?
현재 기사가 여러분의 문제를 해결하지 못하는 경우 AI 엔진은 머신러닝 분석(스마트 모델이 방금 만들어져 부정확한 경우가 있을 수 있음)을 통해 가장 유사한 기사를 추천합니다:
다양한 언어의 JSONJSON은 Javascript 표기법을 사용하여 데이터 구조를 레이아웃하는 데이터 형식입니다. 그러나 Javascript가 코드에서 이러한 구조를 나타낼 수 있는 유일한 언어는 아닙니다. 저는 일반적으로 '객체'{}...
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
CC BY-SA 2.5, CC BY-SA 3.0 및 CC BY-SA 4.0에 따라 라이센스가 부여됩니다.