Changes between Version 5 and Version 6 of DeveloperGuidelines/Web2pyInternalsAndTips


Ignore:
Timestamp:
01/05/13 08:54:00 (12 years ago)
Author:
Pat Tressel
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DeveloperGuidelines/Web2pyInternalsAndTips

    v5 v6  
    1111}}}
    1212
    13 Get names of fields in a Table:
     13Get names of fields in a table:
    1414{{{
    1515table.fields()
    1616}}}
    1717
    18 Get Field objects from a Table (field name in {{{fieldname}}}):
     18Get Field objects from a table (field name in {{{fieldname}}}):
    1919{{{
    2020table[fieldname]
     21}}}
     22
     23Read out the whole table:
     24{{{
     25table._db().select(table.ALL)
     26}}}
     27
     28Clear the table (caution, requires foreign key constraints turned off):
     29{{{
     30table.truncate()
    2131}}}
    2232=== Field ===