Centrallix - It's Different than what you Think
Home   |   Technology   |   Screen Shots   |   Download   |   Documentation   |   History   |   For Developers

Search...


Search For:

Index...


Centrallix Documentation

11.2 Sybase Database Connector


Database Connector to Sybase(R) ASE Servers

As with other kinds of remote data access, Centrallix requires a "node object" in the ObjectSystem to represent the connectivity to the remote resource. This section describes the connector used for Sybase database resources.


Usage

The Sybase connector is a structure file, and its name can either end in "_DB" or the extension ".sybdb". Alternatively, it can be stored in a location (for example, a MIME document with attachments) which keeps the resource type ("application/sybase" in this case) along with the resource.


Passwords and Accounts

Centrallix provides several options on how it should authenticate to the Sybase database server.

The first option is to use a static username and password for all connections; in that case, the username and password are stored in the Sybase connector node.

Alternatively, Centrallix can use the user's Centrallix login credentials when connecting to the database server. Note that in that case, the database server must be a trusted server, to avoid a compromise of the user's login credentials. In the default configuration file, however, the option enable_send_credentials is set to 0 so that Centrallix will refuse to send the user's Centrallix login password to a Sybase ASE server.

Centrallix can also perform a rudimentary form of password synchronization with the database server, to permit the quick deployment of a Centrallix and Sybase setup on an existing server with existing user accounts.


Primary Keys

Centrallix requires that all tables have primary keys. For Sybase tables, the primary key can either be declared using sp_primarykey, or it can be declared using primary key constraints (e.g., via ALTER TABLE or CREATE TABLE).


Object Model

The Sybase driver presents the contents of the remote database using a conventional Centrallix object model for relational data sources:

DatabaseNode_DB/TableName/{rows|columns}/{columnname|rowname}


For example, to access a single row object by name (in this case, a row with primary key value '1000' in the Account table in a database referenced by connector node My_DB):

/datasources/My_DB/Account/rows/1000


To query for rows in the same table, an SQL SELECT statement might look like:

SELECT * from /datasources/My_DB/Account/rows



Properties

Below is a list of the properties used in a Sybase connector node.

PropertyTypeDefaultDescription
databasestring(none)The name of the database to use on the remote server.
serverstring(none)The name of the database server to use, from the Sybase "interfaces" file.
max_connectionsinteger16The maximum number of connections that this driver will make to the remote database. This number can range from 1 to 256.
annot_tablestring(none)The table to use as the "annotation table". This table should have three columns named a, b, and c. 'a' should be the name of the table, 'b' should be a brief description of the table, and 'c' is an expression to evaluate which will give a description of a row in the table.
use_system_authyes/nonoWhether to use the Centrallix login username and password to log into the database server. If set to "no", then Centrallix will use the username and password that are supplied in the Sybase connector node. This option cannot be set to "yes" if the Centrallix system-wide enable_send_credentials option is set to 0.
set_passwordsyes/nonoIf use_system_auth is set to yes, this can be used to perform initial synchronization of Sybase database passwords with the Centrallix login passwords. Should a user's login fail, Centrallix will attempt to login with a default password instead. If the default password login succeeds, then Centrallix will proceed to run Sybase's sp_password stored procedure to change the user's password to no longer be the default and instead be the user's Centrallix login password.
usernamestringcxguestIf use_system_auth is not enabled, this provides the login username that Centrallix will use for the Sybase database server.
passwordstring(empty)If use_system_auth is not enabled, this provides the login password that Centrallix will use for the Sybase database server.
default_passwordstring(empty)If use_system_auth is enabled, this provides the login password that Centrallix will use for the Sybase database server if the user's normal Centrallix login password does not work. Note that this will occur regardless of whether set_passwords is enabled or not.



Sample Connector Node

Here is a sample Sybase connector node which connects to the database My_DB on the server SYB_LOCALHOST. It uses a user's Centrallix system login credentials to connect to the server, and sets a limit of 50 connections.

$Version=2$
My_DB "application/sybase"
    {
    server = "SYB_LOCALHOST"; // from interfaces file
    database = "My_DB";
    max_connections = 50;
    annot_table = "CXAnnotation";
    use_system_auth = yes;
    default_password = "";
    }



Sybase is a registered trademark of Sybase, Inc.

Comments...


(none yet)

Add a Comment...


Your Name:
Comment:


(c) 2001-2020 LightSys Technology Services, Inc. All trademarks are property of their respective owners.

Project Hosting Provided By:
Hosted by Sourceforge