rahulserver
unread,May 20, 2012, 12:16:27 PM5/20/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to web...@googlegroups.com
I have 2 tables:
db.define_table('Transaction_Master',Field('Account',db.Account_Master,requires=IS_IN_DB(db,'Account_Master.id', '%(Account)s %(State)s',zero=T('choose one'))),Field('Exam_Date','date'),Field('Entry_Date','date',default=request.now),Field('Form_1','upload'),Field('Form_1_Name'),
Field('Schoolwise_Form','upload'),Field('Schoolwise_Form_Name'),format='%(Account)s %(Exam_Date)s')
and:
db.define_table('Transactions',Field('TID',db.Transaction_Master),Field('School'),Field('Number_of_students','integer'))
The db.Transactions table will be populated by the excel sheet in Transaction_Master.Schoolwise_Form which contains the list of school names and number of students. I wish to add a computed column in the first table(virtual) which will simply sum up the number of students in Transactions referenced by Transaction_Master.tid. How do i do it?