Menu

timestamp?

2004-07-21
2004-07-22
  • Nobody/Anonymous

    How to create class property reference
    data column timestamp?

    Thank you

    Alan

     
    • Richard Banks

      Richard Banks - 2004-07-21

      Hi Alan,

      If you want to map a property to a MySQL timestamp column, I think you may have to map an long integer property.  Maybe someone with more MySQL experience can help on that one.

      For createddate/modifieddate timestamps (AtomsFramework) you should map these to DATETIME columns, not TIMESTAMP columns.

      I hope that helps,
      - Richard.

       
    • Nobody/Anonymous

      Hello Richard...
      In my project, we use MSSQL 2000 to perform DB Server,we suffer a problem when we want to use TimeStamp to identify the consistence of the record.When we want to update the record we selected , we cannot find a way to skip the alert of the TimeStamp columns of the record.

      Thank You
      Alan

       
    • Richard Banks

      Richard Banks - 2004-07-22

      Hi Alan,

      On SQL Server you should use datetime fields.  Create a column called modified (or something) and in the mapping map the ModifiedDate attribute to that column.

      When the framework attempts to update a record the where clause includes information about the expected modified and created dates.  If the record has been modified by someone else then the update will fail (as the where clause will not match any records) and you will get an exception raised.

      Does that help explain things?
      - Richard.

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.