# ContactsContract.AggregationExceptions

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)

# AggregationExceptions

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/android/provider/ContactsContract.AggregationExceptions "View this page in Java")  

```
class AggregationExceptions : BaseColumns
```

|---|--------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)                                                                                     ||
| ↳ | [android.provider.ContactsContract.AggregationExceptions](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#) |

Constants for the contact aggregation exceptions table, which contains aggregation rules overriding those used by automatic aggregation. This type only supports query and update. Neither insert nor delete are supported.

## Columns

|                                                                                                                                                                                                                                                                                                                            AggregationExceptions                                                                                                                                                                                                                                                                                                                            ||||
|------|---------------------------------------------------------------------------------------------------------------------------------------------------------|------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| int  | [TYPE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE:kotlin.String)                       | read/write | The type of exception:[TYPE_KEEP_TOGETHER](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_TOGETHER:kotlin.Int),[TYPE_KEEP_SEPARATE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_SEPARATE:kotlin.Int)or[TYPE_AUTOMATIC](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_AUTOMATIC:kotlin.Int). |
| long | [RAW_CONTACT_ID1](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#RAW_CONTACT_ID1:kotlin.String) | read/write | A reference to the[RawContacts._ID](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_ID:kotlin.String)of the raw contact that the rule applies to.                                                                                                                                                                                                                                                                                                                   |
| long | [RAW_CONTACT_ID2](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#RAW_CONTACT_ID2:kotlin.String) | read/write | A reference to the other[RawContacts._ID](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_ID:kotlin.String)of the raw contact that the rule applies to.                                                                                                                                                                                                                                                                                                             |

## Summary

|                                                                                                                                                                                                                                                                                                                                                         Constants                                                                                                                                                                                                                                                                                                                                                          ||
|----------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| static[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [CONTENT_ITEM_TYPE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#CONTENT_ITEM_TYPE:kotlin.String) The MIME type of a[CONTENT_URI](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#CONTENT_URI:android.net.Uri)subdirectory of an aggregation exception                                                                                                                                                                                                                                                            |
| static[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [CONTENT_TYPE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#CONTENT_TYPE:kotlin.String) The MIME type of[CONTENT_URI](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#CONTENT_URI:android.net.Uri)providing a directory of data.                                                                                                                                                                                                                                                                                  |
| static[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [RAW_CONTACT_ID1](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#RAW_CONTACT_ID1:kotlin.String) A reference to the[RawContacts._ID](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_ID:kotlin.String)of the raw contact that the rule applies to.                                                                                                                                                                                                                                                                                             |
| static[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [RAW_CONTACT_ID2](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#RAW_CONTACT_ID2:kotlin.String) A reference to the other[RawContacts._ID](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_ID:kotlin.String)of the raw contact that the rule applies to.                                                                                                                                                                                                                                                                                       |
| static[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [TYPE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE:kotlin.String) The type of exception:[TYPE_KEEP_TOGETHER](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_TOGETHER:kotlin.Int),[TYPE_KEEP_SEPARATE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_SEPARATE:kotlin.Int)or[TYPE_AUTOMATIC](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_AUTOMATIC:kotlin.Int). |
| static[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)       | [TYPE_AUTOMATIC](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_AUTOMATIC:kotlin.Int) Allows the provider to automatically decide whether the specified raw contacts should be included in the same aggregate contact or not.                                                                                                                                                                                                                                                                                                                                         |
| static[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)       | [TYPE_KEEP_SEPARATE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_SEPARATE:kotlin.Int) Makes sure that the specified raw contacts are NOT included in the same aggregate contact.                                                                                                                                                                                                                                                                                                                                                                              |
| static[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)       | [TYPE_KEEP_TOGETHER](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_TOGETHER:kotlin.Int) Makes sure that the specified raw contacts are included in the same aggregate contact.                                                                                                                                                                                                                                                                                                                                                                                  |

| Inherited constants ||
|---|---|
| From class[BaseColumns](https://developer.android.com/reference/kotlin/android/provider/BaseColumns) |----------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [_COUNT](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_COUNT:kotlin.String) <br /> The count of rows in a directory. Type: INTEGER <br /> | | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [_ID](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_ID:kotlin.String) <br /> The unique ID for a row. Type: INTEGER (long) <br />         | ||

|                                                                                                                                  Properties                                                                                                                                   ||
|------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| static[Uri](https://developer.android.com/reference/kotlin/android/net/Uri.html#)! | [CONTENT_URI](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#CONTENT_URI:android.net.Uri) The content:// style URI for this table |

## Constants

### CONTENT_ITEM_TYPE

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val CONTENT_ITEM_TYPE: String
```

The MIME type of a[CONTENT_URI](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#CONTENT_URI:android.net.Uri)subdirectory of an aggregation exception  

    Value: "vnd.android.cursor.item/aggregation_exception"

### CONTENT_TYPE

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val CONTENT_TYPE: String
```

The MIME type of[CONTENT_URI](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#CONTENT_URI:android.net.Uri)providing a directory of data.  

    Value: "vnd.android.cursor.dir/aggregation_exception"

### RAW_CONTACT_ID1

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val RAW_CONTACT_ID1: String
```

A reference to the[RawContacts._ID](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_ID:kotlin.String)of the raw contact that the rule applies to.  

    Value: "raw_contact_id1"

### RAW_CONTACT_ID2

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val RAW_CONTACT_ID2: String
```

A reference to the other[RawContacts._ID](https://developer.android.com/reference/kotlin/android/provider/BaseColumns#_ID:kotlin.String)of the raw contact that the rule applies to.  

    Value: "raw_contact_id2"

### TYPE

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val TYPE: String
```

The type of exception:[TYPE_KEEP_TOGETHER](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_TOGETHER:kotlin.Int),[TYPE_KEEP_SEPARATE](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_KEEP_SEPARATE:kotlin.Int)or[TYPE_AUTOMATIC](https://developer.android.com/reference/kotlin/android/provider/ContactsContract.AggregationExceptions#TYPE_AUTOMATIC:kotlin.Int).

Type: INTEGER  

    Value: "type"

### TYPE_AUTOMATIC

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val TYPE_AUTOMATIC: Int
```

Allows the provider to automatically decide whether the specified raw contacts should be included in the same aggregate contact or not.  

    Value: 0

### TYPE_KEEP_SEPARATE

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val TYPE_KEEP_SEPARATE: Int
```

Makes sure that the specified raw contacts are NOT included in the same aggregate contact.  

    Value: 2

### TYPE_KEEP_TOGETHER

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val TYPE_KEEP_TOGETHER: Int
```

Makes sure that the specified raw contacts are included in the same aggregate contact.  

    Value: 1

## Properties

### CONTENT_URI

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
static val CONTENT_URI: Uri!
```

The content:// style URI for this table