조회 조건
조회 조건은 검색을 위해 정의하는 기준입니다.
조회 조건은 조회의 Find 파트 아래에 표시됩니다.
기본적으로 조회는 비즈니스 규칙에서 실행되지만 비즈니스 규칙(예: 서술형 규칙, 의사결정 테이블 또는 회사에 특정한 다른 유형의 규칙)의 특정 유형을 검색할 수도 있습니다. 예를 들면 다음과 같습니다.
또한 폴더(규칙 패키지), 규칙 플로우, 스마트 폴더, 함수 또는 변수 세트를 검색할 수도 있습니다.
프로젝트 요소의 작동 버전, 즉 현재 Decision Center에서 선택된 기준선에서 참조하는 버전만 조회할 수 있습니다.
조회할 프로젝트 요소를 선택하여 시작하십시오. 그런 다음 조건문 다음에 such that문의 형태로 필터를 추가하여 조회를 정제할 수 있습니다.
예제
Find all business rules such that the effective date of each business rule is after 31/1/2016 and the effective date of each business rule is before 28/2/2016
특성: 특성별 필터 참조
비즈니스 용어: 비즈니스 용어별 필터 참조
규칙 동작: 실행 중 규칙 동작별 필터 참조
규칙 영향: 실행 중 규칙 영향별 필터 참조
현재 세션에서 어느 규칙이 변경되었는 지(after my login time를 조회하여) 또는 어느 규칙을 변경했는 지(creator is me를 조회하여) 식별할 수 있습니다.
특성별 필터
조회되고 있는 프로젝트 요소의 특성 중 하나에 따라 조회를 필터링할 수 있습니다(프로젝트 요소 특성 참조).
예를 들어, 다음 조회는 상태가 new인 비즈니스 규칙만 표시합니다.
Find all business rules such that the status of each business rule is new
비즈니스 용어별 필터
조건 및 규칙의 조치에서 사용되는 비즈니스 용어에 따라 조회를 필터링할 수 있습니다. 이 유형의 필터는 정책 변경으로 영향을 받는 규칙을 찾아낼 때 유용합니다. 예를 들면 다음과 같습니다.
Find all business rules such that each business rule modifies the value of the insurance rate
다음의 조회 구성은 비즈니스 용어를 사용하거나 수정하는 규칙을 찾아냅니다.
- uses the value of
특정 비즈니스 용어의 값을 사용하는 규칙을 리턴합니다.
예제
다음 조회는 대출 등급 값을 사용하는 모든 비즈니스 규칙을 리턴합니다.
Find all business rules such that each business rule uses the value of the loan grade in 'a report'
- uses the phrase
주어진 비즈니스 용어를 호출하는 규칙을 리턴합니다.
예제
다음 조회는 '대출 보고서의 통합 점수에 추가함'을 사용하는 모든 비즈니스 규칙을 리턴합니다.
Find all business rules such that each business rule uses the phrase [ add 'a number' to the corporate score in 'a report' ]
- uses the phrase ... where
제한조건이 적용되는 비즈니스 용어를 호출하는 규칙을 리턴합니다.
예제 1
다음 조회는 '대출자'의 신용평점을 '숫자'로 설정하는 조건을 호출하는 모든 비즈니스 규칙을 리턴하는데, 여기서 숫자는 100과 같을 수 있습니다.
Find all business rules such that each business rule uses the phrase [ set the credit score of 'a borrower' to 'a number' , where 'a number' equals 100 ]
이 조회는 다음 규칙을 리턴합니다.
if the age of 'the borrower' is 30 then set the credit score of 'the borrower' to 100;
예제 2
다음 조회는 '대출자'의 신용평점을 '숫자'로 설정하는 조건을 호출하는 모든 비즈니스 규칙을 리턴하는데, 여기서 숫자는 100 이상일 수 있습니다.
Find all business rules such that each business rule uses the phrase [ set the credit score of 'a borrower' to 'a number' , where 'a number' is at least 100 ]
이 조회는 다음 규칙을 리턴합니다.
if the age of 'the borrower' is 30 then set the credit score of 'the borrower' to 200;
예제 3
다음 조회는 '대출자'에게 '숫자'를 할인해주는 조건을 호출하는 모든 비즈니스 규칙을 리턴하는데, 여기서 '대출자'의 신용평점은 200점 이하일 수 있습니다.
Find all business rules such that each business rule uses the phrase [give the discount 'a number' to 'a borrower' where the credit score of 'a borrower' is at most 200]
제한조건에 언급된 요소가 규칙에 표시되지 않을 때 이 규칙은 리턴됩니다. 다음 규칙에서 '대출자'가 골드 카테고리에 속한다는 사실은 '대출자'의 신용평점이 최대 200일 수 있다는 가능성을 제외합니다.
이 조회는 다음 규칙을 리턴합니다.
if the category of 'the borrower' is Gold then give the discount 10 to 'the borrower';
이 조회는 다음 규칙을 리턴하지 않습니다.
if the credit score of 'the borrower' equals 300 then give the discount 10 to 'the borrower';
- modifies the value of
특정 비즈니스 용어를 수정하는 규칙을 리턴합니다.
예제
다음 조회는 보험료의 값을 수정하는 모든 의사결정 테이블을 리턴합니다.
Find all decision tables such that each decision table modifies the value of 'the insurance rate'
실행 중 규칙 동작별 필터
규칙의 시맨틱, 즉 실행 중 동작에 따라 조회를 필터링할 수 있습니다. 이 유형의 필터는 특정 조건이 참이거나 참이 될 때 적용 가능한 규칙을 찾습니다. 이 필터는 예상대로 작동하도록 실행되는 규칙 하위의 조건을 테스트하는 데 유용합니다.
다음의 시맨틱 조회 구성을 사용할 수 있습니다.
- may apply when
조건 파트가 조회 조건을 충족하거나 조회 조건에 상반되는 규칙 조건에 아무 것도 없는 모든 규칙을 리턴합니다. 따라서 이 조회는 조회 조건과 관련이 없는 조건에 규칙을 포함할 수 있습니다.
예제
규칙 1: If the score of the borrower is at least 10 then...
규칙 2: If the age of the borrower is at least 21 then...
규칙 3: If the score of the borrower is less than 10 and the age of the borrower is more than 35 then...
조회 1:
Find all business rules such that each business rule may apply when the score of the borrower is 20
조회 2:
Find all business rules such that each business rule may apply when the score of the borrower is 5
조회 1은 규칙 1 및 규칙 2를 리턴합니다. 대출자의 점수가 10 이상이면 20일 수도 있기 때문에 규칙 1을 리턴합니다. 대출자의 점수가 20일 수 있다는 조건을 유지할 수 없다고 구체적으로 말하는 것이 규칙 2에 아무것도 없기 때문에 규칙 2를 리턴합니다. 규칙을 적용할 수 없다고 구체적으로 표시하는 조건(10 이하의 점수)이 있기 때문에 규칙 3을 리턴하지 않습니다.
조회 2는 규칙 2와 규칙 3을 리턴합니다. 조회 조건은 점수를 10 미만으로 설정하기 때문에 규칙 1을 적용할 수 없습니다. 규칙 2에서 점수가 5일 때 규칙을 적용할 수 없게 하는 것이 아무것도 없습니다. 규칙 3에서 조건 중 하나 이상을 적용할 수 있고, 점수가 5일 수 있다는 사실을 취소하는 다른 조건에는 아무것도 없습니다.
- may become applicable when
조건 파트가 조회 조건을 충족하는 규칙만 리턴하는 보다 구체적인 조회입니다. 조회 조건과 관련이 없는 조건에서는 규칙을 리턴하지 않습니다.
예제
규칙 3: If the category of the customer is Platinum then...
규칙 4: If the category of the customer is not Platinum then...
규칙 5: If the age of the customer is at most 65 then...
규칙 6: If the age of the customer is at most 65 and the category of the customer is not Platinum...
조회 1:
Find all business rules such that each business rule may become applicable when the category of 'a customer' is Gold
이 조회는 규칙 4와 규칙 6을 리턴합니다. 고객의 카테고리가 플래티넘이 아니고 골드인 경우 규칙 4를 리턴합니다. 동일한 이유로 규칙 6을 리턴합니다. 고객의 연령과 관련있는 추가 조건은 카테고리가 골드일 수도 있는 조건과 모순되지 않습니다.
고객 카테고리가 플래티늄일 때 적용되는 규칙은 카테고리가 골드일 때 적용되지 않기 때문에 이 조회는 규칙 3을 리턴하지 않습니다. 이 조회의 경우 고객 카테고리가 골드이고 고객 연령이 이 조회와 관련없을 때 적용할 수 있는 규칙을 찾고 있기 때문에 규칙 5를 리턴하지 않습니다. 달리 말하면, 규칙 조건은 고객 카테고리가 골드라는 사실에 영향받지 않습니다.
조회 2:
Find all business rules such that each business rule may become applicable when [the age of 'a customer' is at least 21]
이 조회의 경우 고객의 연령이 21 이상일 때 "적용가능"한 규칙을 검색하기 때문에 규칙 5는 리턴하지 않습니다. 고객이 연령이 21 미만인 경우에도 규칙 5는 적용 가능합니다. 따라서 규칙 5는 "적용가능"하게 되지 않지만, 고객 연령이 21 미만에서 21 이상으로 변경될 경우에도 "적용 가능"합니다.
- may lead to a state where
실행되고 나면 조회 조건을 충족하는 결과를 표시할 수 있는 규칙을 리턴합니다. 이 조회는 규칙의 조건 및 실행 파트를 모두 고려합니다. 결과에 따라 규칙을 필터링합니다. 따라서 조회 조건에 영향을 주지 않는 규칙을 리턴하지 않습니다.
예제
규칙 7: If the age of the borrower is at least 25 then set the credit score of the borrower to 60
규칙 8: If the age of the borrower is more than 18 and less than 25 then set the credit score of the borrower to 20
조회:
Find all business rules such that each business rule may lead to a state where the credit score of the borrower is more than 50
대출자의 연령이 검사되고 신용평점이 설정되면, 규칙 7만 50이 넘는 결과를 표시하기 때문에 규칙 8이 아닌 규칙 7을 리턴합니다.
실행 중 규칙 영향별 필터
규칙간 링크 및 종속성을 식별하여 규칙을 필터링할 수 있습니다. 규칙을 실행하면 다른 규칙의 적용성에 어떤 영향을 주고 규칙이 다른 규칙의 실행으로 어떤 영향을 받는 지 검사할 수 있습니다.
- may select
주어진 규칙을 선택해도 되는 규칙 플로우 및 규칙 태스크를 리턴합니다.
예제
다음 조회는 "규칙 1"을 선택해도 되는 규칙 플로우 및 규칙 태스크를 리턴합니다.
Find all ruleflows such that each ruleflow may select "Rule 1"
- may enable rule
주어진 규칙을 적용할 수 있는 규칙을 리턴합니다.
예제
규칙 1:
if the age of the customer is 25 then set the category of the customer to Bronze ;
규칙 2:
if the category of the customer is Bronze then give Champagne to the shopping cart of the customer with message: "Congratulations" ;
조회:
Find all business rules such that each business rule may enable "Rule 2"
고객의 카테고리를 브론즈로 설정하고 규칙 2의 조건이 유효하기 때문에 이 조회는 규칙 1을 리턴합니다.
- may disable
주어진 규칙을 적용할 수 없는 규칙을 리턴합니다.
예제
규칙 1:
if the age of the customer is 18 then set the category of the customer to Copper ;
규칙 2:
if the category of the customer is Bronze then give Champagne to the shopping cart of the customer with message: "Congratulations" ;
규칙 3:
if the age of the customer equals 25 and the category of the customer is Bronze then set the category of the customer to Diamond ;
조회:
Find all business rules such that each business rule may disable "Rule 2"
이 조회는 규칙 1 및 규칙 3을 리턴합니다. 고객 카테고리가 코퍼로 설정되고 브론즈가 될 수 없기 때문에 규칙 1을 리턴합니다. 조건중 하나가 고객 카테고리가 브론즈라고 해도 조치가 고객 카테고리를 다이아몬드로 설정해야 하기 때문에 규칙 3을 리턴합니다. 따라서 고객 카테고리가 다이아몬드인 경우 규칙 2를 적용할 수 없습니다.
- may be enabled by
주어진 규칙에 의해 적용할 수 있는 규칙을 리턴합니다.
예제
규칙 1:
if the age of the customer is 18 then set the category of the customer to Copper ;
규칙 2:
if the category of the customer is Bronze then give Champagne to the shopping cart of the customer with message: "Congratulations" ;
규칙 3:
if the age of the customer equals 25 and the category of the customer is Gold then set the category of the customer to Diamond ;
조회:
Find all business rules such that each business rule may disable "Rule 2"
이 조회는 규칙 1을 리턴합니다. 고객 카테고리가 코퍼로 설정되고 브론즈가 될 수 없기 때문에 규칙 1을 리턴합니다. 조치가 고객 카테고리를 다이아몬드로 설정되고 카테고리가 이미 브론즈가 아닌 상태에서만 실행될 수 있기 때문에 규칙 3을 리턴하지 않습니다. 따라서 규칙 3은 규칙 1을 사용하지 않도록 설정하지 않습니다.
- 로 인해 불가능하게 될 수 있습니다
주어진 규칙에 의해 적용할 수 없는 규칙을 리턴합니다.
예제
규칙 1:
if the age of the customer is 25 then set the category of the customer to Bronze ;
규칙 2:
if the age of the customer equals 25 and the category of the customer is Copper then set the category of the customer to Gold
조회:
Find all business rules such that each business rule may be disabled by "Rule 1"
이 조회는 규칙 1에 의해 적용할 수 없기 때문에 규칙 2를 리턴합니다. 규칙 1에서 연령이 25세인 고객 카테고리는 브론즈로 설정되기 때문에 코퍼가 될 수 없습니다.