The OEM Edition of SQL Anywhere does not permit any operations to be carried out on an unauthenticated database.
You can use the Authenticated database property to determine if the database has been authenticated:
SELECT DB_PROPERTY ( 'Authenticated' ); |
For more information about database properties, see Database properties.
Set the database_authentication option for the database, using the following SQL authentication statement:
SET OPTION PUBLIC.database_authentication='company=company-name; application=application-name; signature=database-signature'; |
Line breaks have been added to the syntax example to improve readability. However, the syntax should be executed without line breaks and without spaces between the equal sign and semi-colons.
The company-name and application-name arguments are the values you supplied to Sybase when obtaining your signature, and database-signature is the database signature that you received from Sybase.
Restart the database for the option to take effect.
When the database server loads an authenticated database, it displays a message in the database server messages window describing the authenticated company and application. You can check that this message is present to verify that the database_authentication option has taken effect. The message has the following form:
This database is licensed for use with: Application: application-name Company: company-name |
You can store the authentication statement in a SQL script file to avoid having to type in the long signature. You can run the SQL script from Interactive SQL by choosing Run Script from the File menu.
If you create a file named authenticate.sql in the scripts subdirectory of your SQL Anywhere installation directory and store the authentication statement in this file, it is applied whenever you create, rebuild, or upgrade a database. See Upgrading authenticated databases.
Discuss this page in DocCommentXchange.
|
Copyright © 2010, iAnywhere Solutions, Inc. - SQL Anywhere 12.0.0 |