Building a set of users and groups allows you to manage permissions on a database. Another aspect of database security and management is to limit the resources an individual user can use.
For example, you may want to prevent a single connection from taking too much of the available memory or CPU resources, so you can avoid having a connection slow down other users of the database.
SQL Anywhere provides a set of database options that the DBA can use to control resources. These options are called resource governors.
You can set database options using the SET OPTION statement, with the following syntax:
SET [ TEMPORARY ] OPTION ... [ userid. | PUBLIC. ]option-name = [ option-value ]
You can use the following options to manage resources:
max_cursor_count Limits the number of cursors for a connection. See max_cursor_count option [database].
max_statement_count Limits the number of prepared statements for a connection .See max_statement_count option [database].
background_priority Limits the impact requests on the current connection have on the performance of other connections. See background_priority option [database].
Database option settings are not inherited through the group structure.