First, bear in mind that through "manifest typing", the type of a
column is not necessarily indicative of the column's contents.

That being said, try:

http://www.sqlite.org/pragma.html#pragma_table_info

On Sun, Feb 20, 2011 at 10:41 AM, paul zazzarino
<[email protected]> wrote:
> Has anyone ever inspected the column type of a field in an SQL Lite Database
> dyanmically ?
>
> For example with the Cursor c you extract the current column name via    str
> = c.getColumnName(columnIndex)
>
> We want to extract the column type dynamically based on the column index
> but there appears to be no call to do this. There is however a getclassname
> but it does not take a columnindex as a parameter. The idea here is to
> scroll through the table and figure out the types and perform conversion by
> dynamically querying the types.
>
> So the equivalent of c.getColumnObject(int colindex)
>
> or c.getColumnType(int colindex) is what is required here
>
> and type would be Blob, Short, String, Long, Int, Float.
>
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Android Discuss" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/android-discuss?hl=en.
>



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Warescription: Three Android Books, Plus Updates, One Low Price!

-- 
You received this message because you are subscribed to the Google Groups 
"Android Discuss" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/android-discuss?hl=en.

Reply via email to