Andrew Wood <ajw...@theiet.org> wrote:
> Ive been looking at the function
> 
> sqlite3_column_decltype
> 
> and am a little confused as to its use.
> 
> How can I find out the declared type of a column.
> 
> As I understand this function, I would have to do a single col select first

Not necessarily a single-column one. The second parameter of the function is 
the column number. Also, you don't need to actually run the query - it's enough 
to just prepare it.

> (select col1 from table) then pass that prepared
> statement to ?  sqlite3_column_decltype 
> 
> Then for the second col change the query to "select col2 from table" and 
> repeat.

You can do "select col1, col2, col3 from mytable;" and query all columns at 
once.
-- 
Igor Tandetnik

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to