If the user ID associated with the server has permission to access the file, the file can be opened for read-only access if it is in the $SYBASE/shared directory. Read access is not allowed for any other $SYBASE directory.
Write access, including file creation, is never allowed
for any $SYBASE directory.
Files opened for write access are given additional checks before the file open request is granted. Adaptive Server checks that:
The user issuing the file-open request is the file owner.
The number of hard links is no more than one. If greater than one, the request fails.
The file to be opened is in a valid directory location. The request fails if the file is in the $SYBASE directory or not in one of the configured working directories.
The working directory has been configured with an access mask that allows files to be opened with write access. The default mask is 0666. The mask is not required unless you want a mask other than the default.