Description

When ADF Developers want to filter data without filtering in the Database, they have a possibility to make this with the data in memory using a view criteria object.
The view criteria object is a set of one or more view criteria rows, whose attributes mirror those in the view object.

Example

In the following example we will filter a table with a view criteria. The table consists of four columns:
(Workday; this is the filter attribute), (Startime), (ClosingTime) and (Break).
The view object has the name (TimelogView)
1

First we need to define the filter parameters, in this example they are “fromDate” and “toDate”
2

After that we have to edit the view criteria. We name it “TimelogViewCriteria” with a view object where clause. The query execution mode used here is both, this is useful when you want to filter from uncommitted records also.

3

4If we now look in the AppModuleDataControl we will see that a new operation called “ExecuteWithParams” was provided with our two Parameters “fromDate” and “toDate”

5

And now with a drop down in our jsf page, we will create a new ADF parameter form

6And the filter look like this:

7

In our example we have edited some data in the table and we want to filter it:

9

 

The result after filter looks:

10

Wir bleiben für Sie da!

In unserem neusten Blog-Beitrag sprechen wir mit zwei neuen Mitarbeitern, die Mitten in der Corona-Krise bei virtual7 angefangen haben.

Welche Eigenheiten und Herausforderungen einen Jobwechsel in dieser Zeit bedeuten und wie ihr erster Arbeitstag im Home-Office ausgesehen hat, erfahren Sie in diesem Beitrag.