standard fields wnels2  2009-01-21 03:28
Status: Closed
 
In the demo module's SQL scripts the a comment indicates that there are standard fields in a LabKey table.
    -- standard fields
    _ts TIMESTAMP DEFAULT now(),
    RowId SERIAL,
    CreatedBy USERID,
    Created TIMESTAMP,
    ModifiedBy USERID,
    Modified TIMESTAMP,
    Owner USERID NULL

But, not all of the LabKey tables use these fields. What are they used for and when are they required?

Thanks,
Bill
 
 
Matthew Bellew responded:  2009-01-21 08:14
No, none of these fields are required. They do, however, get somewhat special treatment if the do exists. These fields may get set/updated automatically by the system even if they are not explicitly set by the user (say through a form post).
 
wnels2 responded:  2009-01-21 09:38
Thanks. One more quick question please. Where is the port number for the postgres database set in Labkey.
 
adam responded:  2009-01-21 09:45
The standard LabKey configuration specifies no port, which means connections will use the default PostgreSQL port, 5432. You can change the connection string (directly in labkey.xml or indirectly in the build via pg.properties) to specify whatever port you want. http://jdbc.postgresql.org/documentation/83/connect.html