Lesson 2: Connecting to the database

In this lesson, you connect to a sample database. You can choose to use Sybase Central or Interactive SQL to connect.

 Connect to the sample database
  1. Start Sybase Central or Interactive SQL.

    • To start Sybase Central, click Start » Programs » SQL Anywhere 12 » Administration Tools » Sybase Central.

    • To start Interactive SQL, Start » Programs » SQL Anywhere 12 » Administration Tools » Interactive SQL.

  2. Click Connections » Connect With SQL Anywhere 12.

  3. Complete the following fields to connect to the database:

    1. In the User ID field, type DBA.

    2. In the Password field, type sql.

    3. In the Action dropdown list click Connect To A Running Database On This Computer.

    4. In the Server Name field, type demo12.

      Note

      Your computer may be running software that has an embedded SQL Anywhere server, in which case there could be multiple servers running without you realizing it. You should always specify the server name (ServerName=server-name).

  4. Click Connect

    The administrative tool connects to the database.

  5. Optional. Query the Customers table in Interactive SQL.

    1. In the SQL Statements pane, type the following:

      SELECT * FROM Customers;
    2. Run the statement. Press F5 or click SQL » Execute to execute the statement.

      The result set appears in the Results pane.

  6. Proceed to Lesson 3: Stopping the database server.

 See also