Upgrade SQL Anywhere Consolidated database
1. If you are upgrading the SQL anywhere Consolidated database, please upgrade the database to version 10 first:
A. Shutting down the database server
B. Upgrading the database to version 10
C. Start the database server and log on as a DBA
2. If you upgrade from version 6.x, you need to run the Mobilink setup script that is located in the Mobilink\setup subdirectory under the SQL Anywhere installation directory. If you upgrade from an updated version, you do not need to run the setup script.
3, run the appropriate upgrade script.
Upgrade foot name for Upgrade_asa.sql. Their mobilink\upgrade\version,version in the SQL Anywhere installation directory is the version of SQL anywhere before the upgrade.
To run the upgrade script, you must impersonate the dbo user, which can be implemented using the SETUSER SQL statement.
For example, upgrade version 9.0.2 SQL anywhere consolidated database, use interactive SQL to connect to the database, and run the following command:
SETUSER "dbo";
READ ' C:\Program files\sql Anywhere 10\mobilink\upgrade\9.0.2\upgrade_asa.sql '
4, remove the dbo password. For example:
GRANT CONNECT to "dbo"
5. If you start the Mobilink server as a non-DBA user, you must grant the user permission to execute the new Mobilink system object. The following code grants the necessary permissions for all Mobilink system objects. Before executing this code, you must replace the My_user in your code with the user who started the Mobilink server.
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_column to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_connection_script to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_database to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_device to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_device_address to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_listening to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_property to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_qa_clients to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_qa_delivery to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_qa_global_props to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_qa_notifications to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_qa_repository to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_qa_repository_props to
My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_qa_repository_staging to
My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_qa_status_history to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_qa_status_staging to
My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_script to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_script_version to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_scripts_modified to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_sis_sync_state to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_subscription to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on dbo.ml_table to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_table_script to My_user;
GRANT SELECT, INSERT, UPDATE, DELETE on Dbo.ml_user to My_user;
GRANT EXECUTE on Dbo.ml_qa_get_agent_network_property to My_user;
GRANT EXECUTE on Dbo.ml_qa_get_agent_object_property to My_user;
GRANT EXECUTE on Dbo.ml_qa_get_agent_property to My_user;
GRANT EXECUTE on Dbo.ml_qa_get_message_property to My_user;
GRANT EXECUTE on Dbo.ml_add_column to My_user;
GRANT EXECUTE on Dbo.ml_add_connection_script to My_user;
GRANT EXECUTE on Dbo.ml_add_dnet_connection_script to My_user;
GRANT EXECUTE on Dbo.ml_add_dnet_table_script to My_user;
GRANT EXECUTE on Dbo.ml_add_java_connection_script to My_user;
GRANT EXECUTE on Dbo.ml_add_java_table_script to My_user;
GRANT EXECUTE on Dbo.ml_add_lang_conn_script_chk to My_user;
GRANT EXECUTE on Dbo.ml_add_lang_connection_script to My_user;
GRANT EXECUTE on Dbo.ml_add_lang_table_script to My_user;
GRANT EXECUTE on Dbo.ml_add_lang_table_script_chk to My_user;
GRANT EXECUTE on Dbo.ml_add_property to My_user;
GRANT EXECUTE on Dbo.ml_add_table_script to My_user;
GRANT EXECUTE on Dbo.ml_add_user to My_user;
GRANT EXECUTE on Dbo.ml_delete_device to My_user;
GRANT EXECUTE on dbo.ml_delete_device_address to My_user;
GRANT EXECUTE on dbo.ml_delete_listening to My_user;
GRANT EXECUTE on dbo.ml_delete_sync_state to My_user;
GRANT EXECUTE on Dbo.ml_delete_sync_state_before to My_user;
GRANT EXECUTE on Dbo.ml_delete_user to My_user;
GRANT EXECUTE on Dbo.ml_qa_add_delivery to My_user;
GRANT EXECUTE on Dbo.ml_qa_add_message to My_user;
GRANT EXECUTE on Dbo.ml_qa_handle_error to My_user;
GRANT EXECUTE on dbo.ml_qa_stage_status_from_client to My_user;
GRANT EXECUTE on dbo.ml_qa_staged_status_for_client to My_user;
GRANT EXECUTE on Dbo.ml_qa_upsert_global_prop to My_user;
GRANT EXECUTE on dbo.ml_reset_sync_state to My_user;
GRANT EXECUTE on Dbo.ml_set_device to My_user;
GRANT EXECUTE on dbo.ml_set_device_address to My_user;
GRANT EXECUTE on dbo.ml_set_listening to My_user;
GRANT EXECUTE on dbo.ml_set_sis_sync_state to My_user;
GRANT EXECUTE on dbo.ml_upload_update_device_address to My_user;
GRANT EXECUTE on dbo.ml_upload_update_listening to My_user;