I am parsing data out of files and inputting this data into a sqlite db. 
 One file may have multiple username entries.  The data looks something 
like this:

[['tom', 324],['dick', 246],['harry', 112]]

The first item in each list is obviously the name.  The second line is the 
line number (i used enumerate) from my parsed file.

I want to be able to display html like follows:

Line: 324 - tom
Line: 246 - dick
Line: 112 - harry

I'd like to be able to access items in my lists by index; however, 
everything inside my individual lists are strings.  Do I have to convert 
the strings back to a list?

Example:

The following returns ['tom', 324]

Field('username', represent = lambda x, row: x[0]),

While this returns '['

Field('username', represent = lambda x, row: x[0][0]),


I'd rather not have to convert every line back into a list....is there a 
better way to do this?

-- 
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/groups/opt_out.

Reply via email to