it works, and I thought I tried this before... thank you so much!!

On Wednesday, November 14, 2012 3:31:31 PM UTC-6, Cliff Kachinske wrote:

> I always just use.
>
> *
> Rows = db(db.bike.id==request.args(0)).select()
> *
>
> This assumes you are constructing the URLs correctly.
>
> localhost:8000/<appname>/<controllername>/tag/1
>
>
> I never reassign request.args(<any number>) unless I'm going to use it a 
> lot and want to save some typing. Same with request.vars.  
>
> On Tuesday, November 13, 2012 6:28:59 PM UTC-5, Paul Rykiel wrote:
>>
>> Hi just learning WEB2py and I have a question:
>>  
>> why do i get an error on this code
>> **** This code errors out, but when I replace "tag_no" with 1 for record 
>> id 1, it works, also the variable "tag_no" has a 1 as a value when i type 
>> in an argument 1 on the end of the URL *
>>  
>> def tag():
>>     tag_no = request.args(0) 
>>     Title = "For Sale"
>>   *  Rows = db(db.bike.id==tag_no).select()   *
>>     for row in Rows:
>>          serial = row.serial
>>          make = row.make
>>          model = row.model
>>          size = row.size
>>          color = row.color
>>          style = row.style
>>          date_of_receipt = row.date_of_receipt
>>          repairs = row.repairs_done
>>          price = row.price
>>     return locals()
>>
>

-- 



Reply via email to