[web2py] Re: SQLFORM.grid, groupby and sum/count

2017-01-19 Thread James Booth
Hm, so there's no real way to do this at the minute? The problem is, if I do it via executesql or virtual fields, I can't export it as CSV which is my primary goal. On Monday, January 16, 2017 at 1:01:01 PM UTC, Jurgis Pralgauskis wrote: > > Hi, > > I think it echoes my isssues >

[web2py] SQLFORM.grid, groupby and sum/count

2017-01-16 Thread James Booth
Hey guys, I'm trying to create a SQLFORM.grid that will display the total number of entries for each 'user' in a certain time period. Basically, my model states that a user can only be in bursary_entries table once per day (This equates to a user swiping their ID card). I would like to be

[web2py] SQLFORM.Grid - Export CSV to contain 'links' too

2016-11-29 Thread James Booth
Hey guys, I currently have the following: db.define_table('bursary_users', Field('forename', type='string', requires=IS_NOT_EMPTY()), Field('surname', type='string', requires=IS_NOT_EMPTY()), Field('studentId', type='string',

[web2py] Re: Referencing another table

2016-10-15 Thread James Booth
Okay, that seems to work fine, I guess I just tried to implement into incorrectly. Thanks for your help! -- 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) ---

[web2py] Re: Referencing another table

2016-10-15 Thread James Booth
requirements > 'reference bursary_users' == requires = IS_IN_DB(db, 'bursary_users.*id*') > > > > > > > > On Friday, October 14, 2016 at 6:21:38 PM UTC+3, James Booth wrote: >> >> Hey guys, >> >> Excuse me if I'm missing something (or a lot), but I'm

[web2py] Referencing another table

2016-10-14 Thread James Booth
And that was meant to be INexperienced with web2py. It's been a long week. -- 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

[web2py] Referencing another table

2016-10-14 Thread James Booth
Hey guys, Excuse me if I'm missing something (or a lot), but I'm pretty experienced with web2py. I have the following defined in my model: db.define_table('bursary_users', > Field('forename', type='string', requires=IS_NOT_EMPTY()), > Field('surname',