오픈된 Statement 갯수 보기 쿼리
select sid, count(*) cnt from v$open_cursor
where user_name = 'TRANIZ'
group by sid
order by cnt desc


연결된 세션 갯수 보기
select sid, count(*) cnt from v$session
where username = 'TRANIZ'
group by sid
order by cnt desc  
netstat 명령어

netstat 명령어는 활성 TCP 연결, 컴퓨터 수신 포트, 이더넷 통계, IP 라우팅 테이블, IPv4 통계(IP, ICMP, TCP, UDP 프로토콜에 대한 통계), IPv6 통계(IPv6, ICMPv6, IPv6를 통한 TCP, IPv6를 통한 UDP 통계)를 표시한다.

이 명령어를 매개 변수 없이 사용할 경우 디폴트로 활성 TCP 연결을 표시한다.

서버 동시 접속자 수 알아내기

명령어 구문

※ 매개변수

사용예제
※ 참고 :
TCP 연결 상태 설명


구분 Java 5.0 ActionScript 3.0
라이브러리
패키징
.jar .swc
상속 class Employee extends Person{…} class Employee extends Person{…}
변수정의 및
초기화
String firstName=”John”;
Date shipDate=new Date();

int i;
int a, b=10;
double salary;
var firstName:String=”John”;
var shipDate:Date=new Date();

var i:int;

var a:int, b:int=10;
var salary:Number;
정의되지 않은 변수 N/A It’s an equivalent to the wild card type notation *.
If you declare a variable but do not specify its type, the * type will apply.

A default value: undefined var myVar:*;
변수 scopes block: declared within curly braces,
local: declared within a method or a block
member: declared on the class level
no global variables
No block scope: the minimal scope is a function
local: declared within a function
member: declared on the class level
If a variable is declared outside of any function or class definition, it has global scope.
문자열(String) 2바이트 유니코드의 불변값 좌동
문장 종료 시
세미콜론(;) 사용
필수 라인별로 구분되면 생략가능
Strict equality operator N/A === for strict non-equality use !==
상수 final 키워드로 정의
final int STATE=”NY”;
const 키워드로 정의
const STATE:int =”NY”;
Type 체킹 Static (checked at compile time) Dynamic (checked at run-time) and static (it’s so called ‘strict mode’, which is default in Flex Builder)
Type 체킹
연산자
instanceof is (instanceof - 예전방식)
as 연산자 N/A var orderId:String=”123”;
var orderIdN:Number=orderId as Number;
trace(orderIdN); // prints 123
기본형 byte, int, long, float, double,short, boolean, char 모든 기본형은 ActionScript 오브젝트임.
Boolean, int, uint, Number, String
아래 문장은 같은 의미임.

var age:int = 25;
var age:int = new int(25);
복잡한 유형 N/A Array, Date, Error, Function, RegExp, XML, 그리고 XMLList
배열 및 초기화 int quarterResults[]; quarterResults =
new int[4];

int quarterResults[]={25,33,56,84};
var quarterResults:Array
=new Array();
또는
var quarterResults:Array=[];
var quarterResults:Array=
[25, 33, 56, 84];
특히, 인덱스 값 대신에 이름을 통해 요소에 접근가능함 (Hashtable 처럼)
최상위 클래스 Object Object
객체 캐스팅
(형변환)

Person p=(Person) myObject;

var p:Person= Person(myObject);
또는
var p:Person= myObject as Person;

UP 캐스팅
(다형성)

class Xyz extends Abc{}

Abc myObj = new Xyz();

class Xyz extends Abc{}

var myObj:Abc=new Xyz();

가변유형 N/A var myObject:* var myObject:
패키지 구문
package com.xyz;
class myClass {…}
package com.xyz{
     class myClass{…}

}
접근 레벨 public, private, protected, default 좌동
Custom access levels: namespaces N/A Similar to XML namespaces. namespace abc;
abc function myCalc(){}
or abc::myCalc(){}
use namespace abc ;
콘솔출력 System.out.println(); trace();
임포트 구문
import com.abc.*;
import com.abc.MyClass;
좌동
Unordered key-value pairs Hashtable, Map
Hashtable friends = new Hashtable();
friends.put(”good”,
“Mary”);
friends.put(”best”,
“Bill”);
friends.put(”bad”,
“Masha”);
String bestFriend= friends.get(“best”); // bestFriend is Bill
Associative Arrays
Allows referencing its elements by names instead of indexes.

var friends:Array=new Array();
friends[”good”]=”Mary”;

friends[”best”]=”Bill”;

friends[”bad”]=”Masha”;

var bestFriend:String= friends[“best”]

friends.best=”Alex”;
Another syntax:

var car:Object = {make:”Toyota”, model:”Camry”};

trace (car[”make”], car.model); // Output: Toyota Camry

Hoisting N/A Compiler moves all variable declarations to the top of the function, so you can use a variable name even before it’s been explicitly declared in the code.
클래스
인스턴스화
Customer cmr = new Customer();
Class cls = Class.forName(“Customer”);
Object myObj= cls.newInstance();
var cmr:Customer = new Customer(); var cls:Class = flash.util.getClassByName(”Customer”);
var myObj:Object = new cls();
Private 클래스 private class myClass{…} private 클래스는 없음
Private 생성자 지원
보통 싱글톤에서 사용함
미지원.
Implementation of private constructors is postponed as they are not the part of the ECMAScript standard yet. To create a Singleton, use public static getInstance(), which sets a private flag instanceExists after the first instantiation. Check this flag in the public constructor, and if instanceExists==true, throw an error.
클래스와 파일명 A file can have multiple class declarations, but only one of them can be public, and the file must have the same name as this class. A file can have multiple class declarations, but only one of them can be placed inside the package declaration, and the file must have the same name as this class.
패키지 내에
정의할 수 있는
 항목
Classes 와 interfaces Classes, interfaces, variables, functions, namespaces, and executable statements.
동적 클래스
(define an object that can be altered at runtime by adding or changing properties and methods).
N/A dynamic class Person { var name:String; } //Dynamically add a variable // and a function Person p= new Person();
p.name=”Joe”; p.age=25; p.printMe = function () { trace (p.name, p.age); } p.printMe(); // Joe 25
function closures N/A.
Closure is a proposed addition to Java 7.
myButton.addEventListener(“click”, myMethod);
A closure is an object that represents a snapshot of a function with its lexical context (variable’s values, objects in the scope).
A function closure can be passed as an argument and executed without being a part of any object
추상클래스 지원 N/A
함수 오버라이딩 지원 지원
override 명시해야 함
함수 오버로딩 지원 지원안함
인터페이스 class A implements B{…}
메소드 골격과 final 변수를 정의함
class A implements B{…}
오직 펑션 구문만 정의 가능함
예외처리 try, catch, throw, finally, throws

캐치하지 않은 예외는 호출자에게 전달됨
try, catch, throw, finally

A method does not have to declare exceptions. Can throw not only Error objects, but also numbers:
throw 25.3;
Flash Player terminates the script in case of uncaught exception.
정규식 지원 지원
1. EXPORT

2. IMPORT

3. Export/Import시 주의사항

OPERATION OPTION 설 명
AGGREGATE GROUP BY 그룹함수(SUM, COUNT 등)를 사용하여 하나의 로우가 추출되도록 하는 처리
AND-EQUAL   인덱스 머지를 이용하는 경우 중복 제거, 단일 인덱스 칼럼을 사용하는 경우
CONNECT BY   CONNECT BY를 사용하여 트리구조로 전개
CONCATENATION   단위 액세스에서 추출한 로우들의 합집합을 생성 (UNION-ALL)
COUNTING   테이블의 로우 수를 센다.
FILTER   선택된 로우에 대해서 다른 집합에 대응되는 로우가 있다면 제거하는 작업
FIRST ROW   조회 로우 중에 첫 번째 로우만 추출한다.
FOR UPDATE   선택된 로우에 락(LOCK)을 지정한다.
INDEX* UNIQUE SCAN UNIQUE 인덱스를 사용 (단 한 개의 로우를 추출)
RANGE SCAN NON-UNIQUE한 인덱스를 사용 (한개 이상의 로우)
RANGE SCAN DESCENDING RANGE SCAN하고 동일하지만 역순으로 로우를 추출
INTERSECTION   교집합의 로우를 추출한다.(같은 값이 없다)
MERGE JOIN+   먼저 자신의 조건만으로 액세스한 후 각각을 소트하여 머지해 가는 조인
OUTER 위와 동일한 방법으로 OUTER JOIN을 한다.
MINUS   MINUS 함수를 사용한다.
NESTED LOOPS+   먼저 어떤 드라이빙 테이블의 로우를 액세스한 후 그 결과를 이용해 다른 테이블을 연결하는 조인
OUTER 위와 동일한 방법으로 OUTER JOIN을 한다.
PROJECTION   내부적인 처리의 일종
REMOTE   다른 분산 데이타베이스에 있는 객체를 추출하기 위해 데이타베이스 링크를 사용하는 경우
SEQUENCE   시퀀스를 액세스한다.
SORT AGGREGATE 그룹함수(SUM, COUNT 등)를 사용하여 하나의 로우가 추출되도록 하는 처리
UNIQUE 같은 로우를 제거하기 위한 소트
GROUP BY 액세스 결과를 GROUP BY하기 위한 소트
JOIN 머지 조인을 하기 위한 소트
ORDER BY ORDER BY를 위한 소트
TABLE ACCESS* FULL 전체 테이블 스캔
CLUSTER 클러스터 액세스
HASH 키값에 대한 해쉬 알고리즘을 사용
BY ROWID ROWID를 이용하여 테이블을 추출
UNION   두 집합의 합집합을 구한다. (중복없음)
항상 전체 범위를 구한다.
VIEW   어떤 처리에 의해 생성되는 가상의 집합(뷰)에서 추출한다. (주로 서브쿼리에 의해서 수행된 결과)

+ Recent posts