Connecting to a database on your own computer from Sybase Central or Interactive SQL

In the simplest connection scenario, the database you want to connect to resides on your own computer. If this is the case for you, ask yourself the following questions:

  • Is the database already running on a server? If not, you need to identify the database file so that Sybase Central or Interactive SQL can start it for you. If so, you can specify fewer parameters in the Connect window.
  • Are there multiple databases running on your computer? If there is only one, Sybase Central or Interactive SQL assumes that it is the one you want to connect to, and you don't need to specify it in the Connect window. If so, you need to tell Sybase Central or Interactive SQL which database in particular to connect to.

The procedures below depend on your answers to these questions.

To connect to a database on an already-running local server

  1. Start Sybase Central or Interactive SQL. If the Connect window does not appear:

    • In Sybase Central, choose Connections » Connect With SQL Anywhere 11.
    • In Interactive SQL, choose SQL » Connect.
  2. Click the Identification tab, and type a user ID and a password for the currently-running database.

  3. Do one of the following:

    • If the server is only running one database, click OK to connect to it.
    • If the server is running multiple databases, click the Database tab of the window and specify a database name. This value is usually the database file name, without the path or extension.

To start and connect to a database

  1. Start Sybase Central or Interactive SQL. If the Connect window does not appear:

    • In Sybase Central, choose Connections » Connect With SQL Anywhere 11.
    • In Interactive SQL, choose SQL » Connect.
  2. Click the Identification tab, and type a user ID and a password.

  3. Click the Database tab.

  4. Specify a file in the Database File field (including the full path, name, and extension). You can search for a file by clicking Browse.

  5. If you want the database name for subsequent connections to be different from the file name, enter a name in the Database Name field (without including a path or extension).

Tips

If the database is already loaded (started) on the server, you only need to provide a database name for a successful connection. The database file is not necessary.

You can connect using a data source (a stored set of connection parameters) for either of the above scenarios by selecting the appropriate data source option at the bottom of the Identification tab of the Connect window.

See also