I think your question is why do we provide a Database Abstraction
Layer and not an Object Relational Mapper.
The answer is because the difference is semantic and not functional.
In my view the mapping between tables in relational database and
objects is a too much of a stretching that works well in simple cases
but not in very complex cases. I think the DAL approach is more
transparent since maps more intuitively into the SQL constructs.
Moreover a DAL tends to be faster than an ORM because there is less
metaclass mambo-jumbo.
Yet you can do what you asked using computed fields and virtual fields
as explained here:
http://www.web2py.com/book/default/chapter/06#Computed-fields
Let me give you an example of of why I think our approach is better.
Say you have a table order (with a field quantity and a reference to a
product) and a table product (with a field unit_price). If you join
the table and want a new virtual field total_price ( = quanty*
unit_price) web2py allows you to do so. The virtual fields can be
attached to a table but also to a join while ORM usually do not allow
you do so because results of a joins are not classes.
Massimo