Sybase Technical Library - Product Manuals Home
[Search Forms] [Previous Section with Hits] [Next Section with Hits] [Clear Search] Expand Search

Sybase(R) Adaptive Server(TM) EnterpriseReference Manual [Table of Contents] Chapter 1: System and User-Defined Datatypes

Reference Manual

[-] About This Book

About This Book

The Adaptive Server Reference Manual is a guide to Sybase(R) Adaptive Server(TM) Enterprise and the Transact-SQL(R) language. This book describes the "building blocks" of Transact-SQL, which are datatypes, built-in functions, expressions and identifiers, SQLSTATE errors, and reserved words. Before you can use Transact-SQL successfully, you need to understand the function of each of these building blocks and how its use affects the results of Transact-SQL statements.

This book provides reference information about the Transact-SQL commands, which you use to create statements. It also provides reference information about system procedures, catalog stored procedures, extended stored procedures, and dbcc stored procedures. All procedures are created using Transact-SQL statements.

Reference information is also provided for the system tables, which store information about your server, databases, users, and other information.

Audience

The Adaptive Server Reference Manual is intended as a reference tool for Transact-SQL users of all levels.

How to Use This Book

This manual contains:

Adaptive Server Enterprise Documents

The following documents comprise the Sybase Adaptive Server Enterprise documentation:

Other Sources of Information

Use the Sybase Technical Library CD and the Technical Library Web site to learn more about your product:

Conventions Used in This Manual

The following sections describe conventions used in this manual.

Formatting SQL Statements

SQL is a free-form language. There are no rules about the number of words you can put on a line or where you must break a line. However, for readability, all examples and syntax statements in this manual are formatted so that each clause of a statement begins on a new line. Clauses that have more than one part extend to additional lines, which are indented.

Font and Syntax Conventions

Table 1 shows the conventions for syntax statements that appear in this manual:

Table 1: Font and syntax conventions for this manual

Element

Example

Command names, command option names, utility names, utility options, and other keywords are bold.

select
sp_configure

Database names, datatypes, file names and path names are in italics.

master database

Variables, or words that stand for values that you fill in, are in italics.

select column_name
from table_name
where search_conditions

Type parentheses as part of the command.

compute row_aggregate (column_name)

Curly braces mean that you must choose at least one of the enclosed options. Do not type the braces.

{cash, check, credit}

Brackets mean that to choose one or more of the enclosed options is optional. Do not type the brackets.

[cash | check | credit]

The comma means you may choose as many of the options shown as you want. Separate your choices with commas as part of the command.

cash, check, credit

The pipe or vertical bar(|) means you may select only one of the options shown.

cash | check | credit

An ellipsis (...) means that you can repeat the last unit as many times as you like.

buy thing = price [cash | check | credit]
[, thing = price [cash | check | credit] ]...

You must buy at least one thing and give its price. You may choose a method of payment: one of the items enclosed in square brackets. You may also choose to buy additional things: as many of them as you like. For each thing you buy, give its name, its price, and (optionally) a method of payment.

Case

In this manual, most of the examples are in lowercase. However, you can disregard case when typing Transact-SQL keywords. For example, SELECT, Select, and select are the same.

Adaptive Server's sensitivity to the case of database objects, such as table names, depends on the sort order installed on Adaptive Server. You can change case sensitivity for single-byte character sets by reconfiguring the Adaptive Server sort order. For more information, see "Changing the Default Character Set, Sort Order, or Language" in Chapter 19, "Configuring Character Sets, Sort Orders, and Languages" in the System Administration Guide.

Expressions

Adaptive Server syntax statements use several different types of expressions.

Table 2: Types of expressions used in syntax statements 

Usage

Definition

expression

Can include constants, literals, functions, column identifiers, variables or parameters

logical expression

An expression that returns TRUE, FALSE or UNKNOWN

constant expression

An expression that always returns the same value, such as "5+3" or "ABCDE"

float_expr

Any floating-point expression or expression that implicitly converts to a floating value

integer_expr

Any integer expression, or an expression that implicitly converts to an integer value

numeric_expr

Any numeric expression that returns a single value

char_expr

Any expression that returns a single character-type value

binary_expression

An expression that returns a single binary or varbinary value

If You Need Help

Each Sybase installation that has purchased a support contract has one or more designated people who are authorized to contact Sybase Technical Support. If you cannot resolve a problem using the manuals or online help, please have the designated person contact Sybase Technical Support or the Sybase subsidiary in your area.


Sybase(R) Adaptive Server(TM) EnterpriseReference Manual [Table of Contents] Chapter 1: System and User-Defined Datatypes