The DAL parses all integer values into Python *long* integers 
<https://docs.python.org/2/library/stdtypes.html#numeric-types-int-float-long-complex>.
 
The representation of long integers includes a trailing "L", but the "L" is 
not included when converting to a string:

>>> mylongint = long(5)
>>> repr(mylongint)
5L

>>> str(mylongint)
5

Anthony

On Thursday, October 27, 2016 at 12:53:06 AM UTC-4, xgp.lat...@gmail.com 
wrote:
>
> Hi all,
>
> Got this query: 
>
> for row in db().select( db.XXXXX.YYYYYY.year(), distinct=True, 
> orderby=db.XXXXX.YYYYYY.year(), ):
>      ayears.append(  row[ db.XXXXX.YYYYYY.year() ] )
>      count = db( db.XXXXX.YYYYYY.year() == row( db.XXXXX.YYYYYY.year() ) 
> ).count()
>
>
> Don't know why all rows return the values with an L at the end of the of 
> it: [2015L, 6249L, 2016L, 9632L] 
> This doesnt happend when its html print.
>
>
> Any ideas?
>
>
> Regards,
>
>
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
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/d/optout.

Reply via email to