Here you can use IPredicateExpression and IRelationPredicateBucket and add in those almost anything. You also can use natural language to add criteria:
IRelationPredicateBucket filter = new RelationPredicateBucket();
// this is a LIKE predicate
filter.Add(CustomerFields.CompanyName % "%some company.."%);
So, if you have a search form, you could something like:
if (!string.IsNullOrEmpty(txtFirstName.Text))
{
filter.Add(CustomerFields.FisrtName == txtFirstName.Text);
}
if (!string.IsNullOrEmpty(txtLastName.Text))
{
filter.Add(CustomerFields.LastName == txtLastName.Text);
}
...
// then use that IRelationPredicateBucket at your fetch routing
If you are using LLBLGenProDataSource(2) to bind the results to some control (say a grid), you can filter on-the-fly without write any code.