DataCategoryFilter
Specify and adjust single condition.
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.aboveOrBelow('Europe__c')
).toList();
Methods
The following are methods for DataCategory Filter
.
FIELDS
with
Signature
DataCategoryFilter with(String field);
Example
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c ABOVE_OR_BELOW Europe__c
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.aboveOrBelow('Europe__c')
).toList();
COMPERATORS
at
WITH DATA CATEGORY Geography__c AT Europe__c
Signature
DataCategoryFilter at(String category);
DataCategoryFilter at(Iterable<String> categories);
Example
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c AT Europe__c
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.at('Europe__c')
).toList();
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c AT (Europe__c, North_America__c)
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.at(new List<String>{ 'Europe__c', 'North_America__c' })
).toList();
above
WITH DATA CATEGORY Geography__c ABOVE Europe__c
Signature
DataCategoryFilter above(String category);
DataCategoryFilter above(Iterable<String> categories);
Example
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c ABOVE Europe__c
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.above('Europe__c')
).toList();
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c ABOVE (Europe__c, North_America__c)
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.above(new List<String>{ 'Europe__c', 'North_America__c' })
).toList();
below
WITH DATA CATEGORY Geography__c BELOW Europe__c
Signature
DataCategoryFilter below(String category);
DataCategoryFilter below(Iterable<String> categories);
Example
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c BELOW Europe__c
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.below('Europe__c')
).toList();
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c BELOW (Europe__c, North_America__c)
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.below(new List<String>{ 'Europe__c', 'North_America__c' })
).toList();
aboveOrBelow
WITH DATA CATEGORY Geography__c ABOVE_OR_BELOW Europe__c
Signature
DataCategoryFilter aboveOrBelow(String category);
DataCategoryFilter aboveOrBelow(Iterable<String> categories);
Example
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c ABOVE_OR_BELOW Europe__c
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.aboveOrBelow('Europe__c')
).toList();
SELECT Id, Title
FROM Knowledge__kav
WITH DATA CATEGORY Geography__c ABOVE_OR_BELOW (Europe__c, North_America__c)
SOQL.of(Knowledge__kav.SObjectType)
.with(Knowledge__kav.Id, Knowledge__kav.Title)
.withDataCategory(
SOQL.DataCategoryFilter
.with('Geography__c')
.aboveOrBelow(new List<String>{ 'Europe__c', 'North_America__c' })
).toList();