Terry Carroll wrote:
> GET_TABLE_INFO_COMMAND = "PRAGMA TABLE_INFO(?)"
> pragma_cmd = GET_TABLE_INFO_COMMAND
> field_data = self.dbconn.execute(pragma_cmd, (tablename))
> 
> I get the error:
> 
>   sqlite3.OperationalError: near "?": syntax error
> 
> Some of the variations included using "tablename" or "(tablename,)" for 
> the second parameter; it made no difference.

FWIW (tablename,) or [tablename] is the correct spelling, the parameter 
argument must be a sequence.

Kent
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to