getFilterList() Method

Usage

public java.lang.String getFilterList( java.lang.String pStart, 
java.lang.String pPattern, 
java.lang.String pSeparator, 
java.lang.String pEnd)

Alternative syntax:

public java.lang.String getFilterList(
java.lang.String pPattern, 
java.lang.String pSeparator)

Description

Offers a list of occurrences of the SQL filters of an interface.

The parameter pPattern is interpreted and repeated for each element of the list and separated from its predecessor with parameter pSeparator. The generated string begins with pStart and ends with pEnd.

This list contains an element for each filter expression executed on the source or target (depending on the Knowledge Module in use).

In the alternative syntax, any parameters not set are set to an empty string.

Parameters

Parameter

Type

Description

pStart

String

This sequence marks the beginning of the string to generate.

pPattern

String

The pattern will be repeated for each occurrence of the list.

 The list of possible in a list is available in the table « Pattern Attributes List  »

 Each attribute occurrence in the pattern string is substituted with its value. Attributes must be between brackets ([ and ])

Example « My string [COL_NAME] is a column »

pSeparator

String

This parameter is used to separate a pattern from its predecessor.

pEnd

String

This sequence marks the end of the string to generate.

Pattern Attributes List

The following table lists the different values of the parameters as well as the associated description.

Parameter value

Description

ID

Filter internal identifier

EXPRESSION

Text of the filter expression.

Examples

insert into <%=odiRef.getTable("L", "COLL_NAME", "W")%>
select <%=odiRef.getColList("", "[EXPRESSION]", ", ", "", "INS=1")%>
from <%=odiRef.getFrom()%>
where (1=1)
<%=odiRef.getJoin()%>
<%=odiRef.getFilterList("and ","([EXPRESSION])"," and ","")%>

<%=odiRef.getGrpBy()%>
<%=odiRef.getHaving()%>

Explanation: the getFilterList function will be used to generate the filter of the SELECT clause that must begin with "and" and repeats the pattern (expression of each filter) separated with "and" for each filter. Thus