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.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
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
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
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.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
How to create class property reference
data column timestamp?
Thank you
Alan
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.
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
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.