Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 17 » UltraLite - Database Management and Developer Guide » UltraLite database reference » UltraLite options

UltraLite timestamp_increment creation option

Specify the limit on the resolution of timestamp values. As timestamps are inserted into the database, UltraLite truncates them to match this increment.

Syntax
timestamp_increment=value
Allowed values

1 to 60000000 microseconds

Default

1 microsecond

Remarks

For Android devices, use Connection.setOption(OPTION_TIMESTAMP_INCREMENT, value) as an alternative to setting this creation option.

Note that 1000000 microseconds equals 1 second.

You cannot change the timestamp_increment creation option of an existing database. Instead, you must create a new database.

This increment is useful when a DEFAULT TIMESTAMP column is being used as a primary key or row identifier.

From SQL Central, you can set the timestamp increment in any wizard that creates a database. On the New database creation parameters page, click the Timestamp Increment option.

From a client application, set this option as one of the creation options for the CreateDatabase method on the DatabaseManager/ULDatabaseManager class.

Example

To store a value such as '2000/12/05 10:50:53:700', set this creation option to 100000. This value truncates the timestamp after the first decimal place in the seconds component.