Executes a single SQL statement that returns no values.
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-07-16 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-07-16 UTC."],[],[],null,["# androidx.sqlite\n===============\n\n*** ** * ** ***\n\nKotlin \\|[Java](/reference/androidx/sqlite/package-summary \"View this page in Java\")\nCommon/AllAndroid/JVMNative/C/iOS\n\nInterfaces\n----------\n\n|------------------------------------------------------------------------|--------------------------------------------|-----|\n| [SQLiteConnection](/reference/kotlin/androidx/sqlite/SQLiteConnection) | SQLite connection definition. | Cmn |\n| [SQLiteDriver](/reference/kotlin/androidx/sqlite/SQLiteDriver) | An interface to open database connections. | Cmn |\n| [SQLiteStatement](/reference/kotlin/androidx/sqlite/SQLiteStatement) | SQLite statement definition. | Cmn |\n\nExceptions\n----------\n\n|----------------------------------------------------------------------|------------------------------------------------------------------------------------------|---------------|\n| [SQLiteException](/reference/kotlin/androidx/sqlite/SQLiteException) | An exception that indicates that something has gone wrong and a error code was produced. | Cmn android N |\n\nType aliases\n------------\n\n|----------------------------------------------------------------------|---|---------|\n| [SQLiteException](/reference/kotlin/androidx/sqlite/SQLiteException) | | android |\n\nConstants summary\n-----------------\n\n|-------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----|\n| `const `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) | [SQLITE_DATA_BLOB](/reference/kotlin/androidx/sqlite/package-summary#SQLITE_DATA_BLOB())` = 4` The data type for a `BLOB` value, i.e. binary data. | Cmn |\n| `const `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) | [SQLITE_DATA_FLOAT](/reference/kotlin/androidx/sqlite/package-summary#SQLITE_DATA_FLOAT())` = 2` The data type for a 64-bit IEEE floating point number. | Cmn |\n| `const `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) | [SQLITE_DATA_INTEGER](/reference/kotlin/androidx/sqlite/package-summary#SQLITE_DATA_INTEGER())` = 1` The data type for a 64-bit signed integer. | Cmn |\n| `const `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) | [SQLITE_DATA_NULL](/reference/kotlin/androidx/sqlite/package-summary#SQLITE_DATA_NULL())` = 5` The data type for a `NULL` value. | Cmn |\n| `const `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) | [SQLITE_DATA_TEXT](/reference/kotlin/androidx/sqlite/package-summary#SQLITE_DATA_TEXT())` = 3` The data type for a [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html). | Cmn |\n\nTop-level functions summary\n---------------------------\n\n|-------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----|\n| [Nothing](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-nothing/index.html) | [throwSQLiteException](/reference/kotlin/androidx/sqlite/package-summary#throwSQLiteException(kotlin.Int,kotlin.String))`(errorCode: `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)`, errorMsg: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`?)` Throws a [SQLiteException](/reference/kotlin/androidx/sqlite/SQLiteException) with its message formed by the given [errorCode](/reference/kotlin/androidx/sqlite/package-summary#throwSQLiteException(kotlin.Int,kotlin.String)) amd [errorMsg](/reference/kotlin/androidx/sqlite/package-summary#throwSQLiteException(kotlin.Int,kotlin.String)). | Cmn |\n\nExtension functions summary\n---------------------------\n\n|-------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----|\n| [Unit](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html) | [SQLiteConnection](/reference/kotlin/androidx/sqlite/SQLiteConnection)`.`[execSQL](/reference/kotlin/androidx/sqlite/package-summary#(androidx.sqlite.SQLiteConnection).execSQL(kotlin.String))`(sql: `[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)`)` Executes a single SQL statement that returns no values. | Cmn |\n\nConstants\n---------\n\n### SQLITE_DATA_BLOB\n\nCmn \nArtifact: [androidx.sqlite:sqlite](/jetpack/androidx/releases/sqlite) \n[View Source](https://cs.android.com/search?q=file:androidx/sqlite/SQLite.kt+symbol:SQLITE_DATA_BLOB) \nAdded in [2.5.0](/jetpack/androidx/releases/sqlite#2.5.0) \n\n```\nconst val SQLITE_DATA_BLOB = 4: Int\n```\n\nThe data type for a `BLOB` value, i.e. binary data. \n\n### SQLITE_DATA_FLOAT\n\nCmn \nArtifact: [androidx.sqlite:sqlite](/jetpack/androidx/releases/sqlite) \n[View Source](https://cs.android.com/search?q=file:androidx/sqlite/SQLite.kt+symbol:SQLITE_DATA_FLOAT) \nAdded in [2.5.0](/jetpack/androidx/releases/sqlite#2.5.0) \n\n```\nconst val SQLITE_DATA_FLOAT = 2: Int\n```\n\nThe data type for a 64-bit IEEE floating point number. \n\n### SQLITE_DATA_INTEGER\n\nCmn \nArtifact: [androidx.sqlite:sqlite](/jetpack/androidx/releases/sqlite) \n[View Source](https://cs.android.com/search?q=file:androidx/sqlite/SQLite.kt+symbol:SQLITE_DATA_INTEGER) \nAdded in [2.5.0](/jetpack/androidx/releases/sqlite#2.5.0) \n\n```\nconst val SQLITE_DATA_INTEGER = 1: Int\n```\n\nThe data type for a 64-bit signed integer. \n\n### SQLITE_DATA_NULL\n\nCmn \nArtifact: [androidx.sqlite:sqlite](/jetpack/androidx/releases/sqlite) \n[View Source](https://cs.android.com/search?q=file:androidx/sqlite/SQLite.kt+symbol:SQLITE_DATA_NULL) \nAdded in [2.5.0](/jetpack/androidx/releases/sqlite#2.5.0) \n\n```\nconst val SQLITE_DATA_NULL = 5: Int\n```\n\nThe data type for a `NULL` value. \n\n### SQLITE_DATA_TEXT\n\nCmn \nArtifact: [androidx.sqlite:sqlite](/jetpack/androidx/releases/sqlite) \n[View Source](https://cs.android.com/search?q=file:androidx/sqlite/SQLite.kt+symbol:SQLITE_DATA_TEXT) \nAdded in [2.5.0](/jetpack/androidx/releases/sqlite#2.5.0) \n\n```\nconst val SQLITE_DATA_TEXT = 3: Int\n```\n\nThe data type for a [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html).\n\nTop-level functions\n-------------------\n\n### throwSQLiteException\n\nCmn \nArtifact: [androidx.sqlite:sqlite](/jetpack/androidx/releases/sqlite) \n[View Source](https://cs.android.com/search?q=file:androidx/sqlite/SQLite.kt+function:throwSQLiteException) \nAdded in [2.5.0](/jetpack/androidx/releases/sqlite#2.5.0) \n\n```\nfun throwSQLiteException(errorCode: Int, errorMsg: String?): Nothing\n```\n\nThrows a [SQLiteException](/reference/kotlin/androidx/sqlite/SQLiteException) with its message formed by the given [errorCode](/reference/kotlin/androidx/sqlite/package-summary#throwSQLiteException(kotlin.Int,kotlin.String)) amd [errorMsg](/reference/kotlin/androidx/sqlite/package-summary#throwSQLiteException(kotlin.Int,kotlin.String)).\n\nExtension functions\n-------------------\n\n### execSQL\n\nCmn \nArtifact: [androidx.sqlite:sqlite](/jetpack/androidx/releases/sqlite) \n[View Source](https://cs.android.com/search?q=file:androidx/sqlite/SQLite.kt+function:execSQL) \nAdded in [2.5.0](/jetpack/androidx/releases/sqlite#2.5.0) \n\n```\nfun SQLiteConnection.execSQL(sql: String): Unit\n```\n\nExecutes a single SQL statement that returns no values."]]