Delete an android

Report a typo

Luke Skywalker wants to delete android info from the androids table. The android has an id and a name. Please complete the SQL sentence to make it possible.

fun deleteData(android: Android) {
    val sql = /* """ Write your SQL Sentence """ */
    DatabaseManager.open().use { conn ->
        conn.prepareStatement(sql).use { stmt ->
            stmt.setInt(1, android.id)
            stmt.executeUpdate()
        }
    }
}
Enter a short text
___

Create a free account to access the full topic