Added in [API level 19](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [Constants](https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#constants)

# Telephony.TextBasedSmsColumns

*** ** * ** ***


`
public
static


interface
Telephony.TextBasedSmsColumns
`


`


`

|---|
| android.provider.Telephony.TextBasedSmsColumns |

|---|
| Known indirect subclasses [Telephony.Sms](https://developer.android.com/reference/android/provider/Telephony.Sms), [Telephony.Sms.Conversations](https://developer.android.com/reference/android/provider/Telephony.Sms.Conversations), [Telephony.Sms.Draft](https://developer.android.com/reference/android/provider/Telephony.Sms.Draft), [Telephony.Sms.Inbox](https://developer.android.com/reference/android/provider/Telephony.Sms.Inbox), [Telephony.Sms.Outbox](https://developer.android.com/reference/android/provider/Telephony.Sms.Outbox), [Telephony.Sms.Sent](https://developer.android.com/reference/android/provider/Telephony.Sms.Sent) |---|---| | [Telephony.Sms](https://developer.android.com/reference/android/provider/Telephony.Sms) | Contains all text-based SMS messages. | | [Telephony.Sms.Conversations](https://developer.android.com/reference/android/provider/Telephony.Sms.Conversations) | Contains a view of SMS conversations (also referred to as threads). | | [Telephony.Sms.Draft](https://developer.android.com/reference/android/provider/Telephony.Sms.Draft) | Contains all draft text-based SMS messages in the SMS app. | | [Telephony.Sms.Inbox](https://developer.android.com/reference/android/provider/Telephony.Sms.Inbox) | Contains all text-based SMS messages in the SMS app inbox. | | [Telephony.Sms.Outbox](https://developer.android.com/reference/android/provider/Telephony.Sms.Outbox) | Contains all pending outgoing text-based SMS messages. | | [Telephony.Sms.Sent](https://developer.android.com/reference/android/provider/Telephony.Sms.Sent) | Contains all sent text-based SMS messages in the SMS app. | |

<br />

*** ** * ** ***

Base columns for tables that contain text-based SMSs.

## Summary

| ### Constants ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#ADDRESS` The address of the other party. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#BODY` The body of the message. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#CREATOR` The identity of the sender of a sent message. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#DATE` The date the message was received. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#DATE_SENT` The date the message was sent. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#ERROR_CODE` Error code associated with sending or receiving this message Type: INTEGER <br /> |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#LOCKED` Is the message locked? Type: INTEGER (boolean) <br /> |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#MESSAGE_TYPE_ALL` Message type: all messages. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#MESSAGE_TYPE_DRAFT` Message type: drafts. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#MESSAGE_TYPE_FAILED` Message type: failed outgoing message. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#MESSAGE_TYPE_INBOX` Message type: inbox. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#MESSAGE_TYPE_OUTBOX` Message type: outbox. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#MESSAGE_TYPE_QUEUED` Message type: queued to send later. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#MESSAGE_TYPE_SENT` Message type: sent messages. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#PERSON` The ID of the sender of the conversation, if present. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#PROTOCOL` The protocol identifier code. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#READ` Has the message been read? Type: INTEGER (boolean) <br /> |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#REPLY_PATH_PRESENT` Is the `TP-Reply-Path` flag set? Type: BOOLEAN <br /> |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#SEEN` Has the message been seen by the user? The "seen" flag determines whether we need to show a notification. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#SERVICE_CENTER` The service center (SC) through which to send the message, if present. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#STATUS` `TP-Status` value for the message, or -1 if no status has been received. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#STATUS_COMPLETE` TP-Status: complete. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#STATUS_FAILED` TP-Status: failed. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#STATUS_NONE` TP-Status: no status received. |
| `int` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#STATUS_PENDING` TP-Status: pending. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#SUBJECT` The subject of the message, if present. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#SUBSCRIPTION_ID` The subscription to which the message belongs to. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#THREAD_ID` The thread ID of the message. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#TRANSACTION_ID` The `transaction-id` of the message. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/Telephony.TextBasedSmsColumns#TYPE` The type of message. |

## Constants

### ADDRESS

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

```
public static final String ADDRESS
```

The address of the other party.

Type: TEXT

<br />

<br />

Constant Value:

"address"


### BODY

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

```
public static final String BODY
```

The body of the message.

Type: TEXT

<br />

<br />

Constant Value:

"body"


### CREATOR

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

```
public static final String CREATOR
```

The identity of the sender of a sent message. It is
usually the package name of the app which sends the message.

**Note:**
This column is read-only. It is set by the provider and can not be changed by apps.

Type: TEXT

<br />

<br />

Constant Value:

"creator"


### DATE

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

```
public static final String DATE
```

The date the message was received.

Type: INTEGER (long)

<br />

<br />

Constant Value:

"date"


### DATE_SENT

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

```
public static final String DATE_SENT
```

The date the message was sent.

Type: INTEGER (long)

<br />

<br />

Constant Value:

"date_sent"


### ERROR_CODE

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

```
public static final String ERROR_CODE
```

Error code associated with sending or receiving this message

Type: INTEGER

<br />

<br />

Constant Value:

"error_code"


### LOCKED

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

```
public static final String LOCKED
```

Is the message locked?

Type: INTEGER (boolean)

<br />

<br />

Constant Value:

"locked"


### MESSAGE_TYPE_ALL

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

```
public static final int MESSAGE_TYPE_ALL
```

Message type: all messages.

<br />

Constant Value:

0
(0x00000000)


### MESSAGE_TYPE_DRAFT

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

```
public static final int MESSAGE_TYPE_DRAFT
```

Message type: drafts.

<br />

Constant Value:

3
(0x00000003)


### MESSAGE_TYPE_FAILED

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

```
public static final int MESSAGE_TYPE_FAILED
```

Message type: failed outgoing message.

<br />

Constant Value:

5
(0x00000005)


### MESSAGE_TYPE_INBOX

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

```
public static final int MESSAGE_TYPE_INBOX
```

Message type: inbox.

<br />

Constant Value:

1
(0x00000001)


### MESSAGE_TYPE_OUTBOX

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

```
public static final int MESSAGE_TYPE_OUTBOX
```

Message type: outbox.

<br />

Constant Value:

4
(0x00000004)


### MESSAGE_TYPE_QUEUED

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

```
public static final int MESSAGE_TYPE_QUEUED
```

Message type: queued to send later.

<br />

Constant Value:

6
(0x00000006)


### MESSAGE_TYPE_SENT

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

```
public static final int MESSAGE_TYPE_SENT
```

Message type: sent messages.

<br />

Constant Value:

2
(0x00000002)


### PERSON

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

```
public static final String PERSON
```

The ID of the sender of the conversation, if present.

Type: INTEGER (reference to item in `content://contacts/people`)

<br />

<br />

Constant Value:

"person"


### PROTOCOL

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

```
public static final String PROTOCOL
```

The protocol identifier code.

Type: INTEGER

<br />

<br />

Constant Value:

"protocol"


### READ

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

```
public static final String READ
```

Has the message been read?

Type: INTEGER (boolean)

<br />

<br />

Constant Value:

"read"


### REPLY_PATH_PRESENT

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

```
public static final String REPLY_PATH_PRESENT
```

Is the `TP-Reply-Path` flag set?

Type: BOOLEAN

<br />

<br />

Constant Value:

"reply_path_present"


### SEEN

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

```
public static final String SEEN
```

Has the message been seen by the user? The "seen" flag determines
whether we need to show a notification.

Type: INTEGER (boolean)

<br />

<br />

Constant Value:

"seen"


### SERVICE_CENTER

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

```
public static final String SERVICE_CENTER
```

The service center (SC) through which to send the message, if present.

Type: TEXT

<br />

<br />

Constant Value:

"service_center"


### STATUS

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

```
public static final String STATUS
```

`TP-Status` value for the message, or -1 if no status has been received.

Type: INTEGER

<br />

<br />

Constant Value:

"status"


### STATUS_COMPLETE

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

```
public static final int STATUS_COMPLETE
```

TP-Status: complete.

<br />

Constant Value:

0
(0x00000000)


### STATUS_FAILED

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

```
public static final int STATUS_FAILED
```

TP-Status: failed.

<br />

Constant Value:

64
(0x00000040)


### STATUS_NONE

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

```
public static final int STATUS_NONE
```

TP-Status: no status received.

<br />

Constant Value:

-1
(0xffffffff)


### STATUS_PENDING

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

```
public static final int STATUS_PENDING
```

TP-Status: pending.

<br />

Constant Value:

32
(0x00000020)


### SUBJECT

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

```
public static final String SUBJECT
```

The subject of the message, if present.

Type: TEXT

<br />

<br />

Constant Value:

"subject"


### SUBSCRIPTION_ID

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

```
public static final String SUBSCRIPTION_ID
```

The subscription to which the message belongs to. Its value will be
\< 0 if the sub id cannot be determined.

Type: INTEGER (long)

<br />

<br />

Constant Value:

"sub_id"


### THREAD_ID

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

```
public static final String THREAD_ID
```

The thread ID of the message.

Type: INTEGER

<br />

<br />

Constant Value:

"thread_id"


### TRANSACTION_ID

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

```
public static final String TRANSACTION_ID
```

The `transaction-id` of the message.


This column is used by the default messaging app to associate an internal transaction
identifier with a specific SMS message record in the database.


The platform stores the value provided in this column but treats it as an opaque field.
It does not interpret, validate or use the contents of this column for any platform
logic.


Type: TEXT

<br />

<br />

Constant Value:

"tr_id"


### TYPE

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

```
public static final String TYPE
```

The type of message.

Type: INTEGER

<br />

<br />

Constant Value:

"type"