Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 12.0.1 » MobiLink - 客户端管理 » 用于 MobiLink 的 SQL Anywhere 客户端 » 脚本式上载 » 教程:使用脚本式上载

 

第 8 课:演示脚本式上载

本课假定您已完成前面的所有课程。 请参见第 1 课:创建统一数据库

 ♦ 演示脚本式上载
  1. 使用连接到远程数据库的 Interactive SQL 实例,插入要使用脚本式上载进行同步的数据。在远程数据库上运行以下 SQL 语句:

    INSERT INTO employee(id, name, salary) VALUES( 7, 'black', 700 );
    INSERT INTO employee(id, name, salary) VALUES( 8, 'anderson', 800 );
    INSERT INTO employee(id, name, salary) VALUES( 9, 'dilon', 900 );
    INSERT INTO employee(id, name, salary) VALUES( 10, 'dwit', 1000 );
    INSERT INTO employee(id, name, salary) VALUES( 11, 'dwit', 1100 );
    COMMIT;
  2. 在命令提示符处,启动 MobiLink 服务器:

    mlsrv12 -c "DSN=dsn_consol" -o mlserver.mls -v+ -dl -zu+
  3. 使用 dbmlsync 启动同步:

    dbmlsync -c "DSN=dsn_remote" -k -uo -o remote.mlc -v+
  4. 运行以下 SQL 语句验证是否已上载了这些插入。

    select * from employee

    您应看到在本课开头插入的值。

  5. 前进至清理