update() takes a mapping that reflect column names, not fields....

db(db.md5.md5==md5_update).update(db.md5.status=True)

The red part needs to be eliminated

db(db.md5.md5==md5_update).update(status=True)



On Tuesday, May 14, 2013 7:14:03 PM UTC+2, Nam Soo In wrote:
>
> Hi, I am trying to update Database and It keeps giving me an error 
> <type 'exceptions.TypeError'> update() takes exactly 1 argument (2 given)
>
> my database is pretty simple 
> it has md5 and md5 status
> so in the recevied_result there are md5 and
>
>  for md5_update in recevied_result:
>         db(db.md5.md5==md5_update).update(db.md5.status=True)
>
> I want to write a query like this 
>     Update md5 set status=True where md5=md_update
>
> FYI status is boolean type
>
> Any thought 
>
> Thank you in advance
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to