[Tutor] MySQLdb INSERT with while or for loop

R. Alan Monroe R. Alan Monroe" <amonroe@columbus.rr.com
Wed Jun 11 20:47:17 2003


> value=(stock[0])
> print "Value is %s" % value
> cursor.execute("""
>         INSERT INTO stockinfo (symbol)
>         VALUES('@value')
>         """)

How about
cursor.execute( "INSERT INTO stockinfo (symbol)
                VALUES(" + value + ")" )

Alan