I made this a wild ago, but never go any further... Here the thread...

http://groups.google.com/group/web2py/browse_thread/thread/50af0d67554c94d9/dfc30ce6fb4455eb?pli=1




Richard


On Sun, Sep 11, 2011 at 3:55 AM, Serbitar <[email protected]> wrote:
> Sure, I know that. But I am explicitly looking for the convenience of
> crud that also automatically generates the forms for that.
>
> I basically want to auto-generate forms that allow updating of
> multiple values. I know how to do it with custom forms, but that is
> quite tedious. A crud solution would be much better.
>
> On Sep 10, 11:12 pm, Richard Vézina <[email protected]>
> wrote:
>> for fieldvalue in list of values:
>>     db.person.insert(name=fieldvalue)
>>
>> Off coarse you can do it for multiple values :
>>
>> list1=[(valfield1,valfield2,valfield3),(etc.),(etc.)] # Note : first
>> tuples = first rows you want to insert
>>
>> for field1, field2, field3 in list1
>>     db.person.insert(field1=field1, field2=field2, field3=field3)
>>     db.commit # or you wait and the end of the loop better only one commit
>>
>> Richard
>>
>>
>>
>>
>>
>>
>>
>> On Sat, Sep 10, 2011 at 4:12 PM, Serbitar <[email protected]> wrote:
>>
>> > To be more specific:
>>
>> > Multiple records (found via a query), all with different values of
>> > course and one text field for each record. Just one submit button.
>>
>> > On Sep 10, 9:55 pm, Serbitar <[email protected]> wrote:
>> > > is there any way toupdatemultiplerecordswith crud.update, or 
>> > > evenrecordswith a given query?

Reply via email to