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

SQL Anywhere 12.0.1 » SQL Anywhere Server - Database Administration » Database configuration » Connection, database, and database server properties


User-defined properties

SQL Anywhere supports properties that can be set to a user-defined value. Your application must define the semantics for each user-defined property and set the values that are returned. The property values can be set to an absolute value using the sa_user_defined_counter_set system procedure or incremented using the sa_user_defined_counter_add system procedure. The sa_user_defined_counter_add system procedure can also be used to decrement the property by adding a negative value.

The values for user-defined properties are maintained separately for each connection, database, and server. The current value of the properties can be retrieved using the CONNECTION_PROPERTY, DB_PROPERTY, and PROPERTY functions, respectively. These properties can also be accessed from the Performance Monitor. The Performance Monitor displays the current value of a UserDefinedCounterRaw property as an absolute value, and displays the rate of change of a UserDefinedCounterRate within a measurement interval as a rate.

One of example of using these properties is to have a raw property that shows the current number of keys remaining in a key pool. The value of the property would fluctuate up and down over time. At the same time, a rate property could show how quickly keys were being used from the key pool. The value would increase over time as keys are used, and the Performance Monitor would show the rate that keys were used per second.

 See also