Get the proximity of an SQLite column on Android

The SQLite C library has a method sqlite3_column_decltype(). But I can not find the places where the SQLite Android API allows this method to be used. Is there a way to get the declared column type without running SQL (i.e. I can avoid using PRAGMA table_info)?

I could use AbstractWindowedCursor.isBlob(), but it says that it will also return true if the field is NULL. I need something that guarantees me a value equal to the declared column type.

+3
source share
1 answer

Recently, I have become interested in the same thing. The closest I found is that the CursorWindow class has methods with a name isString, isLongetc. But it is unclear whether it is based on intimacy; an interface for these methods requires a row as well as column information.

0
source

Source: https://habr.com/ru/post/1785292/


All Articles