Hello from a novice,

I'am trying to define a field that enables me make my entries sortable 
manually. I choose 'integer' as field type:

db.define_table('image',
 Field('Position', 'integer', label=T('Position')),


In my controller, I use "orderby" to sort the entries:

images = db().select(db.image.ALL, orderby=db.image.Position)

Instead of the desired order: 1, 2, 3, 12, 13
I get: 1, 12, 13, 2, 3


I guess, it is a question of data types bur I couldn't figure it out at all.

Thanks for giving me a hint,
Stephan

-- 

--- 
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to