appds_set_inter_mode
status.i4.v = appds_set_inter_mode(table_name.i1a.r, options.u4.v,
error_text.i1a.r, db_name.i1a.r,
db_server.i1a.r)
This routine will set the in memory interaction mode for specified
Application Data Storage table. It will not change the default
setting. Interaction mode setting changes are only allowed if the table
has not been locked through the Application Data Storage Manager.
Through this routine you can set the values for the following
categories:
-read and write access [APPDS_READ_ONLY | APPDS_READ_WRITE]
-record access
[APPDS_SEQ_ACCESS | APPDS_INDEX_ACCESS | APPDS_KEY_ACCESS]
-record overwrite [APPDS_OVERWRITE_ON | APPDS_OVERWRITE_OFF].
For each of the above categories only one value should be specified,
extra values will be ignored.
table_name name of the APPDS table
options interaction mode mask
(APPDS_READ_ONLY -> sets table to READ ONLY,
APPDS_READ_WRITE -> sets table to READ / WRITE,
APPDS_SEQ_ACCESS -> sets table access mode to
sequential,
APPDS_INDEX_ACCESS -> sets table access mode to
Indexed,
APPDS_KEY_ACCESS -> sets table access mode to Keyed,
APPDS_OVERWRITE_ON -> sets records overwrite ON,
APPDS_OVERWRITE_OFF -> sets records overwrite OFF)
(The above values can be logically 'OR'ed together.)
A zero value indicates that the table interaction mode
is to be reset to the default values. Also, only
tables which do NOT have an array as the first
element in their record structure can have their
record access mode set to APPDS_KEY_ACCESS.
error_text a pointer to a buffer to where any error messages are
placed (NULL indicates that no error text is wanted)
db_name name of the database where the APPDS table is found
(If NULL the default value of APPDS_DEFAULT_DB is used.)
db_server name of the database server
(If NULL the default value of APPDS_DEFAULT_SERVER
is used.)
This function returns ACNET status values as follows:
APPDS_SUCCESS interaction mode setting compete
APPDS_LOCK table is locked and mode changes are not
allowed
APPDS_INVARG invalid argument type
SQL_xxx system error occurred
This function requires the following include files:
appds_h, clib_h, acnet_errors_h
Related functions:
appds_free_table_cache, appds_get_inter_mode, appds_read_record,
appds_write_record, appds_delete_record, appds_key_match_count,
appds_set_db_timeout, appds_get_db_timeout