본문 바로가기

Android

execSQL

 

public void execSQL (String sql)

Since: API Level 1

Execute a single SQL statement that is NOT a SELECT or any other SQL statement that returns data.

It has no means to return any data (such as the number of affected rows). Instead, you're encouraged to use insert(String, String, ContentValues)update(String, ContentValues, String, String[]), et al, when possible.

When using enableWriteAheadLogging(), journal_mode is automatically managed by this class. So, do not set journal_mode using "PRAGMA journal_mode'" statement if your app is using enableWriteAheadLogging()

 

Parameters
sql the SQL statement to be executed. Multiple statements separated by semicolons are not supported.
Throws
SQLException if the SQL string is invalid

 

'Android' 카테고리의 다른 글

sdk 비교  (0) 2013.10.10
앱 목록 얻기 (How to get installed app list)  (0) 2013.10.08
using sqlite  (0) 2013.10.08
directory list  (0) 2013.10.08
completeAddAppWidget  (0) 2013.10.08